/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.ipti.br.tag.bean;

import org.ipti.br.tag.bo.*;
import org.ipti.br.tag.entity.*;
import org.ipti.br.tag.entity.enums.*;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.List;
import javax.enterprise.inject.Model;
import javax.inject.Inject;
import org.ipti.br.tag.util.EncryptionUtil;

/**
 *
 * @author root
 */
@Model
public class MainBean {

    @Inject private ActorBO actorBO;
    @Inject private AddInfoPersonageBO addInfoPersonageBO;
    @Inject private AdditionalInfoBO additionalInfoBO;
    @Inject private AdditionalInfoTypeBO additionalInfoTypeBO;
    @Inject private AddressBO addressBO;
    @Inject private DisciplineBO disciplineBO;
    @Inject private EnrollmentBO enrollmentBO;
    @Inject private EthnicityBO ethnicityBO;
    @Inject private FunctionalityBO functionalityBO;
    @Inject private GrantsBO grantsBO;
    @Inject private HumanBO humanBO;
    @Inject private JuridicBO juridicBO;
    @Inject private LoginBO loginBO;
    @Inject private NationalityBO nationalityBO;
    @Inject private OrganizationBO organizationBO;
    @Inject private PeriodBO periodBO;
    @Inject private PersonageBO personageBO;
    @Inject private PlanBO planBO;
    @Inject private SeasonBO seasonBO;
    @Inject private UnityBO unityBO;
    @Inject private AsksBO askBO;
    @Inject private AliasBO aliasBO;
    @Inject private QuestResultBO questResultBO;
    @Inject private QuestionsBO questionsBO;
    @Inject private ConfigurationsBO configurationsBO;
    @Inject private QuestionsPersonBO questionsPersonBO;
    @Inject private StateBO stateBO;
    @Inject private CityBO cityBO;
    @Inject private NeighborhoodBO neighborhoodBO;
    @Inject private StreetBO streetBO;
    @Inject private ZipcodeBO zipcodeBO;
    @Inject private UnityScheduleBO unityScheduleBO;
    @Inject private WorkBO workBO;
    @Inject private SimpleFrequencyBO simpleFrequencyBO;
    @Inject private HbBO hbBO;

    
    public void personagesInserts(){
        Personage prof = personageBO.find(1266550109L), aluno = personageBO.find(623403461L), newProf, newAluno;
        Organization orgEduInfantil = organizationBO.getOrganizationByName("Infantil");
        Organization orgFundamentalMaior = organizationBO.getOrganizationByName("Fundamental Maior");
        for (Organization org : organizationBO.getOrganizationChildren(orgEduInfantil.getId())) {
            newProf = new Personage("Professor "+org.getName(), org, PersonageType.ALLOCATED, prof);
            newAluno = new Personage("Aluno "+org.getName(), org, PersonageType.MATRICULATED, aluno);
            personageBO.create(newProf);
            personageBO.create(newAluno);
        }
        for (Organization org : organizationBO.getOrganizationChildren(orgFundamentalMaior.getId())) {
            newProf = new Personage("Professor "+org.getName(), org, PersonageType.ALLOCATED, prof);
            newAluno = new Personage("Aluno "+org.getName(), org, PersonageType.MATRICULATED, aluno);
            personageBO.create(newProf);
            personageBO.create(newAluno);
        }
    }
    
    public void schoolInserts(){
        Period integral = periodBO.find(1577044373L);
        for (Unity u : unityBO.getUnitiesPerOrganization(-1439496138L)) {
            Organization orgEduInfantil = organizationBO.getOrganizationByName("Infantil");
            Organization orgFundamentalMenor = organizationBO.getOrganizationByName("Fundamental Menor");
            Organization orgFundamentalMaior = organizationBO.getOrganizationByName("Fundamental Maior");
            Unity educacaoInfantil = new Unity("Educação Infantil", (short) 0, Calendar.getInstance(), null, orgEduInfantil, u, integral, null);
            unityBO.create(educacaoInfantil);
            Unity fundamentalMenor = new Unity("Fundamental Menor", (short) 0, Calendar.getInstance(), null, orgFundamentalMenor, u, integral, null);
            unityBO.create(fundamentalMenor);
            Unity fundamentalMaior = new Unity("Fundamental Maior", (short) 0, Calendar.getInstance(), null, orgFundamentalMaior, u, integral, null);
            unityBO.create(fundamentalMaior);
        }
    }
    
    public void ejaAndInfantil() {
//        Personage secretario = personageBO.getPersonageByName("Secretário(a)");
//
//        //buscar Organizações: Ed.Infantil/Fundamental Maior
//        Organization orgEdInfantil = organizationBO.getOrganizationByName("Infantil");
//        Organization orgFundamentalMaior = organizationBO.getOrganizationByName("Fundamental Maior");
//         
//        //Cria a organização Educação Infantil I/Educação Infantil II/6ºANO/7ºANO/8ºANO/9ºANO
//        Organization oedInfantilI = new Organization("Educação Infantil I", "EII", orgEdInfantil);
//        organizationBO.create(oedInfantilI);
//        Organization oedInfantilII = new Organization("Educação Infantil II", "EIII", orgEdInfantil);
//        organizationBO.create(oedInfantilII);
//        Organization Maiorsextoano = new Organization("6º Ano", "6º Ano", orgFundamentalMaior);
//        organizationBO.create(Maiorsextoano);
//        Organization Maiorsetimoano = new Organization("7º Ano", "7º Ano", orgFundamentalMaior);
//        organizationBO.create(Maiorsetimoano);
//        Organization Maioroitavoano = new Organization("8º Ano", "8º Ano", orgFundamentalMaior);
//        organizationBO.create(Maioroitavoano);
//        Organization Maiornonoano = new Organization("9º Ano", "9º Ano", orgFundamentalMaior);
//        organizationBO.create(Maiornonoano);
//        
//        //busca as funcionalides de cadastrar e consulta
//        Functionality frunity = functionalityBO.find(-1034233543L);
//        Functionality fsunity = functionalityBO.find(399764190L);
//        Functionality fnotas = functionalityBO.find(88210001L);
//        Functionality ffrequencia = functionalityBO.find(419579447L);
//        Functionality fschedule = functionalityBO.find(1063474277L);
//        
//        //cria a funcionalidade de cadastrar/consulta/notas/frequencia/horariosemanal unidade educação infantil/fundamental maior
//        Functionality frEducacaoInfantil = new Functionality("Educação Infantil", frunity, null, null);
//        functionalityBO.create(frEducacaoInfantil);
//        Functionality fsEducacaoInfantil = new Functionality("Educação Infantil", fsunity, null, null);
//        functionalityBO.create(fsEducacaoInfantil);
//        Functionality frFundamentalMaior = new Functionality("Fundamental Maior", frunity, null, null);
//        functionalityBO.create(frFundamentalMaior);
//        Functionality fsFundamentalMaior = new Functionality("Fundamental Maior", fsunity, null, null);
//        functionalityBO.create(fsFundamentalMaior);
//        Functionality fnotasFundamentalMaior = new Functionality("Fundamental Maior", fnotas, null, null);
//        functionalityBO.create(fnotasFundamentalMaior);
//        Functionality ffrequenciaFundamentalMaior = new Functionality("Fundamental Maior", ffrequencia, null, null);
//        functionalityBO.create(ffrequenciaFundamentalMaior);
//        Functionality fscheduleFundamentalMaior = new Functionality("Fundamental Maior", fschedule, null, null);
//        functionalityBO.create(fscheduleFundamentalMaior);
//       
//        //cria a funcionalidade de scedule
//        Functionality fscheduleMaiorsextoano = new Functionality("6º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maiorsextoano.getId(), null);
//        functionalityBO.create(fscheduleMaiorsextoano);
//        Functionality fscheduleMaiorsetimoano = new Functionality("7º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maiorsetimoano.getId(), null);
//        functionalityBO.create(fscheduleMaiorsetimoano);
//        Functionality fscheduleMaioroitavoano = new Functionality("8º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maioroitavoano.getId(), null);
//        functionalityBO.create(fscheduleMaioroitavoano);
//        Functionality fscheduleMaiornonoano = new Functionality("9º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maiornonoano.getId(), null);
//        functionalityBO.create(fscheduleMaiornonoano);
//        
//        //cria a funcionalidade de frequencia
//        Functionality ffrequenciaMaiorsextoano = new Functionality("6º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maiorsextoano.getId(), null);
//        functionalityBO.create(ffrequenciaMaiorsextoano);
//        Functionality ffrequenciaMaiorsetimoano = new Functionality("7º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maiorsetimoano.getId(), null);
//        functionalityBO.create(ffrequenciaMaiorsetimoano);
//        Functionality ffrequenciaMaioroitavoano = new Functionality("8º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maioroitavoano.getId(), null);
//        functionalityBO.create(ffrequenciaMaioroitavoano);
//        Functionality ffrequenciaMaiornonoano = new Functionality("9º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maiornonoano.getId(), null);
//        functionalityBO.create(ffrequenciaMaiornonoano);
//        
//        //cria a funcionalidade de notas 
//        Functionality fnotasMaiorsextoano = new Functionality("6º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maiorsextoano.getId(), null);
//        functionalityBO.create(fnotasMaiorsextoano);
//        Functionality fnotasMaiorsetimoano = new Functionality("7º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maiorsetimoano.getId(), null);
//        functionalityBO.create(fnotasMaiorsetimoano);
//        Functionality fnotasMaioroitavoano = new Functionality("8º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maioroitavoano.getId(), null);
//        functionalityBO.create(fnotasMaioroitavoano);
//        Functionality fnotasMaiornonoano = new Functionality("9º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maiornonoano.getId(), null);
//        functionalityBO.create(fnotasMaiornonoano);
//        
//        //cria a funcionalidade de cadastrar nova unidade educação infantial I e II
//        Functionality fredinfantilI = new Functionality("Educação Infantil I", frEducacaoInfantil, "/educational/registration/unityRegistration.xhtml?organization=" + oedInfantilI.getId(), null);
//        functionalityBO.create(fredinfantilI);
//        Functionality fredinfantilII = new Functionality("Educação Infantil II", frEducacaoInfantil, "/educational/registration/unityRegistration.xhtml?organization=" + oedInfantilII.getId(), null);
//        functionalityBO.create(fredinfantilII);
//        Functionality frMaiorsextoano = new Functionality("6º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maiorsextoano.getId(), null);
//        functionalityBO.create(frMaiorsextoano);
//        Functionality frMaiorsetimoano = new Functionality("7º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maiorsetimoano.getId(), null);
//        functionalityBO.create(frMaiorsetimoano);
//        Functionality frMaioroitavoano = new Functionality("8º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maioroitavoano.getId(), null);
//        functionalityBO.create(frMaioroitavoano);
//        Functionality frMaiornonoano = new Functionality("9º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maiornonoano.getId(), null);
//        functionalityBO.create(frMaiornonoano);
//        
//
//        //cria a funcionalidade de consulta educação infantil I
//        Functionality fsedinfantilI = new Functionality("Educação Infantil I", fsEducacaoInfantil, "/educational/search/unitySearch.xhtml?organization=" + oedInfantilI.getId(), null);
//        functionalityBO.create(fsedinfantilI);
//        Functionality fsedinfantilII = new Functionality("Educação Infantil II", fsEducacaoInfantil, "/educational/search/unitySearch.xhtml?organization=" + oedInfantilII.getId(), null);
//        functionalityBO.create(fsedinfantilII);
//        Functionality fsMaiorsextoano = new Functionality("6º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maiorsextoano.getId(), null);
//        functionalityBO.create(fsMaiorsextoano);
//        Functionality fsMaiorsetimoano = new Functionality("7º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maiorsetimoano.getId(), null);
//        functionalityBO.create(fsMaiorsetimoano);
//        Functionality fsMaioroitavoano = new Functionality("8º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maioroitavoano.getId(), null);
//        functionalityBO.create(fsMaioroitavoano);
//        Functionality fsMaiornonoano = new Functionality("9º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maiornonoano.getId(), null);
//        functionalityBO.create(fsMaiornonoano);
//        
//         //libera o grants de cadastrar schedule
//         Grants gschedule1 = new Grants(fscheduleMaiorsextoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gschedule1);
//        Grants gschedule2 = new Grants(fscheduleMaiorsetimoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gschedule2);
//        Grants gschedule3 = new Grants(fscheduleMaioroitavoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gschedule3);
//        Grants gschedule4 = new Grants(fscheduleMaiornonoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gschedule4);
//        
//        //libera o grants de cadastrar notas
//         Grants gfrequencia1 = new Grants(ffrequenciaMaiorsextoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gfrequencia1);
//        Grants gfrequencia2 = new Grants(ffrequenciaMaiorsetimoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gfrequencia2);
//        Grants gfrequencia3 = new Grants(ffrequenciaMaioroitavoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gfrequencia3);
//        Grants gfrequencia4 = new Grants(ffrequenciaMaiornonoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gfrequencia4);
//        
//        //libera o grants de cadastrar notas
//         Grants gnotas1 = new Grants(fnotasMaiorsextoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gnotas1);
//        Grants gnotas2 = new Grants(fnotasMaiorsetimoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gnotas2);
//        Grants gnotas3 = new Grants(fnotasMaioroitavoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gnotas3);
//        Grants gnotas4 = new Grants(fnotasMaiornonoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(gnotas4);
//        
//        //libera grants da duas funcionalides para o secretário na escola.
//        Grants grants01 = new Grants(fredinfantilI, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants01);
//        Grants grants02 = new Grants(fredinfantilII, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants02);
//        Grants grants03 = new Grants(fsedinfantilI, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants03);
//        Grants grants04 = new Grants(fsedinfantilII, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants04);
//        
//        ///libera os grants de cadastra e consulta os fundametal maior
//        Grants grant1 = new Grants(fsMaiorsextoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant1);
//        Grants grant2 = new Grants(fsMaiorsetimoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant2);
//        Grants grant3 = new Grants(fsMaioroitavoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant3);
//        Grants grant4 = new Grants(fsMaiornonoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant4);
//        Grants grant5 = new Grants(frMaiorsextoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant5);
//        Grants grant6 = new Grants(frMaiorsetimoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant6);
//        Grants grant7 = new Grants(frMaioroitavoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant7);
//        Grants grant8 = new Grants(frMaiornonoano, null, secretario.getId(), null,
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grant8);

    }
    
    public void newInserts() {
        Personage secretario = personageBO.getPersonageByName("Secretário(a)");

        //buscar Organizações: Ed.Infantil/Fundamental Maior
        Organization orgEdInfantil = organizationBO.getOrganizationByName("Infantil");
        Organization orgFundamentalMaior = organizationBO.getOrganizationByName("Fundamental Maior");
         
        //Cria a organização Educação Infantil I/Educação Infantil II/6ºANO/7ºANO/8ºANO/9ºANO
        Organization oedInfantilI = new Organization("Educação Infantil I", "EII", orgEdInfantil);
        organizationBO.create(oedInfantilI);
        Organization oedInfantilII = new Organization("Educação Infantil II", "EIII", orgEdInfantil);
        organizationBO.create(oedInfantilII);
        Organization Maiorsextoano = new Organization("6º Ano", "6º Ano", orgFundamentalMaior);
        organizationBO.create(Maiorsextoano);
        Organization Maiorsetimoano = new Organization("7º Ano", "7º Ano", orgFundamentalMaior);
        organizationBO.create(Maiorsetimoano);
        Organization Maioroitavoano = new Organization("8º Ano", "8º Ano", orgFundamentalMaior);
        organizationBO.create(Maioroitavoano);
        Organization Maiornonoano = new Organization("9º Ano", "9º Ano", orgFundamentalMaior);
        organizationBO.create(Maiornonoano);
        
        //busca as funcionalides de cadastrar e consulta
        Functionality frunity = functionalityBO.find(-1034233543L);
        Functionality fsunity = functionalityBO.find(399764190L);
        Functionality fnotas = functionalityBO.find(88210001L);
        Functionality ffrequencia = functionalityBO.find(419579447L);
        Functionality fschedule = functionalityBO.find(1063474277L);
        
        //cria a funcionalidade de cadastrar/consulta/notas/frequencia/horariosemanal unidade educação infantil/fundamental maior
        Functionality frEducacaoInfantil = new Functionality("Educação Infantil", frunity, null, null);
        functionalityBO.create(frEducacaoInfantil);
        Functionality fsEducacaoInfantil = new Functionality("Educação Infantil", fsunity, null, null);
        functionalityBO.create(fsEducacaoInfantil);
        Functionality frFundamentalMaior = new Functionality("Fundamental Maior", frunity, null, null);
        functionalityBO.create(frFundamentalMaior);
        Functionality fsFundamentalMaior = new Functionality("Fundamental Maior", fsunity, null, null);
        functionalityBO.create(fsFundamentalMaior);
        Functionality fnotasFundamentalMaior = new Functionality("Fundamental Maior", fnotas, null, null);
        functionalityBO.create(fnotasFundamentalMaior);
        Functionality ffrequenciaFundamentalMaior = new Functionality("Fundamental Maior", ffrequencia, null, null);
        functionalityBO.create(ffrequenciaFundamentalMaior);
        Functionality fscheduleFundamentalMaior = new Functionality("Fundamental Maior", fschedule, null, null);
        functionalityBO.create(fscheduleFundamentalMaior);
       
        //cria a funcionalidade de scedule
        Functionality fscheduleMaiorsextoano = new Functionality("6º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maiorsextoano.getId(), null);
        functionalityBO.create(fscheduleMaiorsextoano);
        Functionality fscheduleMaiorsetimoano = new Functionality("7º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maiorsetimoano.getId(), null);
        functionalityBO.create(fscheduleMaiorsetimoano);
        Functionality fscheduleMaioroitavoano = new Functionality("8º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maioroitavoano.getId(), null);
        functionalityBO.create(fscheduleMaioroitavoano);
        Functionality fscheduleMaiornonoano = new Functionality("9º Ano", fscheduleFundamentalMaior, "/educational/schedule/unityschedule.xhtml?organizationID=" + Maiornonoano.getId(), null);
        functionalityBO.create(fscheduleMaiornonoano);
        
        //cria a funcionalidade de frequencia
        Functionality ffrequenciaMaiorsextoano = new Functionality("6º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maiorsextoano.getId(), null);
        functionalityBO.create(ffrequenciaMaiorsextoano);
        Functionality ffrequenciaMaiorsetimoano = new Functionality("7º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maiorsetimoano.getId(), null);
        functionalityBO.create(ffrequenciaMaiorsetimoano);
        Functionality ffrequenciaMaioroitavoano = new Functionality("8º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maioroitavoano.getId(), null);
        functionalityBO.create(ffrequenciaMaioroitavoano);
        Functionality ffrequenciaMaiornonoano = new Functionality("9º Ano", ffrequenciaFundamentalMaior, "/educational/frequency/simplefrequency.xhtml?organization=" + Maiornonoano.getId(), null);
        functionalityBO.create(ffrequenciaMaiornonoano);
        
        //cria a funcionalidade de notas 
        Functionality fnotasMaiorsextoano = new Functionality("6º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maiorsextoano.getId(), null);
        functionalityBO.create(fnotasMaiorsextoano);
        Functionality fnotasMaiorsetimoano = new Functionality("7º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maiorsetimoano.getId(), null);
        functionalityBO.create(fnotasMaiorsetimoano);
        Functionality fnotasMaioroitavoano = new Functionality("8º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maioroitavoano.getId(), null);
        functionalityBO.create(fnotasMaioroitavoano);
        Functionality fnotasMaiornonoano = new Functionality("9º Ano", fnotasFundamentalMaior, "/educational/performance/simpleperformance.xhtml?organization=" + Maiornonoano.getId(), null);
        functionalityBO.create(fnotasMaiornonoano);
        
        //cria a funcionalidade de cadastrar nova unidade educação infantial I e II
        Functionality fredinfantilI = new Functionality("Educação Infantil I", frEducacaoInfantil, "/educational/registration/unityRegistration.xhtml?organization=" + oedInfantilI.getId(), null);
        functionalityBO.create(fredinfantilI);
        Functionality fredinfantilII = new Functionality("Educação Infantil II", frEducacaoInfantil, "/educational/registration/unityRegistration.xhtml?organization=" + oedInfantilII.getId(), null);
        functionalityBO.create(fredinfantilII);
        Functionality frMaiorsextoano = new Functionality("6º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maiorsextoano.getId(), null);
        functionalityBO.create(frMaiorsextoano);
        Functionality frMaiorsetimoano = new Functionality("7º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maiorsetimoano.getId(), null);
        functionalityBO.create(frMaiorsetimoano);
        Functionality frMaioroitavoano = new Functionality("8º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maioroitavoano.getId(), null);
        functionalityBO.create(frMaioroitavoano);
        Functionality frMaiornonoano = new Functionality("9º Ano", frFundamentalMaior, "/educational/registration/unityRegistration.xhtml?organization=" + Maiornonoano.getId(), null);
        functionalityBO.create(frMaiornonoano);
        

        //cria a funcionalidade de consulta educação infantil I
        Functionality fsedinfantilI = new Functionality("Educação Infantil I", fsEducacaoInfantil, "/educational/search/unitySearch.xhtml?organization=" + oedInfantilI.getId(), null);
        functionalityBO.create(fsedinfantilI);
        Functionality fsedinfantilII = new Functionality("Educação Infantil II", fsEducacaoInfantil, "/educational/search/unitySearch.xhtml?organization=" + oedInfantilII.getId(), null);
        functionalityBO.create(fsedinfantilII);
        Functionality fsMaiorsextoano = new Functionality("6º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maiorsextoano.getId(), null);
        functionalityBO.create(fsMaiorsextoano);
        Functionality fsMaiorsetimoano = new Functionality("7º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maiorsetimoano.getId(), null);
        functionalityBO.create(fsMaiorsetimoano);
        Functionality fsMaioroitavoano = new Functionality("8º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maioroitavoano.getId(), null);
        functionalityBO.create(fsMaioroitavoano);
        Functionality fsMaiornonoano = new Functionality("9º Ano", fsFundamentalMaior, "/educational/search/unitySearch.xhtml?organization=" + Maiornonoano.getId(), null);
        functionalityBO.create(fsMaiornonoano);
        
         //libera o grants de cadastrar schedule
         Grants gschedule1 = new Grants(fscheduleMaiorsextoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gschedule1);
        Grants gschedule2 = new Grants(fscheduleMaiorsetimoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gschedule2);
        Grants gschedule3 = new Grants(fscheduleMaioroitavoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gschedule3);
        Grants gschedule4 = new Grants(fscheduleMaiornonoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gschedule4);
        
        //libera o grants de cadastrar notas
         Grants gfrequencia1 = new Grants(ffrequenciaMaiorsextoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gfrequencia1);
        Grants gfrequencia2 = new Grants(ffrequenciaMaiorsetimoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gfrequencia2);
        Grants gfrequencia3 = new Grants(ffrequenciaMaioroitavoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gfrequencia3);
        Grants gfrequencia4 = new Grants(ffrequenciaMaiornonoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gfrequencia4);
        
        //libera o grants de cadastrar notas
         Grants gnotas1 = new Grants(fnotasMaiorsextoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gnotas1);
        Grants gnotas2 = new Grants(fnotasMaiorsetimoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gnotas2);
        Grants gnotas3 = new Grants(fnotasMaioroitavoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gnotas3);
        Grants gnotas4 = new Grants(fnotasMaiornonoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(gnotas4);
        
        //libera grants da duas funcionalides para o secretário na escola.
        Grants grants01 = new Grants(fredinfantilI, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants01);
        Grants grants02 = new Grants(fredinfantilII, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants02);
        Grants grants03 = new Grants(fsedinfantilI, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants03);
        Grants grants04 = new Grants(fsedinfantilII, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants04);
        
        ///libera os grants de cadastra e consulta os fundametal maior
        Grants grant1 = new Grants(fsMaiorsextoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant1);
        Grants grant2 = new Grants(fsMaiorsetimoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant2);
        Grants grant3 = new Grants(fsMaioroitavoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant3);
        Grants grant4 = new Grants(fsMaiornonoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant4);
        Grants grant5 = new Grants(frMaiorsextoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant5);
        Grants grant6 = new Grants(frMaiorsetimoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant6);
        Grants grant7 = new Grants(frMaioroitavoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant7);
        Grants grant8 = new Grants(frMaiornonoano, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant8);

    }

    public void finalInsert() {
        Organization orgAno1 = organizationBO.getOrganizationByName("1º Ano");
        if (orgAno1 != null) {
            System.out.println("ID = " + orgAno1.getId() + " NAME = " + orgAno1.getName());
        }
        Organization orgAno2 = organizationBO.getOrganizationByName("2º Ano");
        if (orgAno2 != null) {
            System.out.println("ID = " + orgAno2.getId() + " NAME = " + orgAno2.getName());
        }
        Organization orgAno3 = organizationBO.getOrganizationByName("3º Ano");
        if (orgAno3 != null) {
            System.out.println("ID = " + orgAno3.getId() + " NAME = " + orgAno3.getName());
        }
        Organization orgAno4 = organizationBO.getOrganizationByName("4º Ano");
        if (orgAno4 != null) {
            System.out.println("ID = " + orgAno4.getId() + " NAME = " + orgAno4.getName());
        }
        Organization orgAno5 = organizationBO.getOrganizationByName("5º Ano");
        if (orgAno5 != null) {
            System.out.println("ID = " + orgAno5.getId() + " NAME = " + orgAno5.getName());
        }

        Personage secretario = personageBO.getPersonageByName("Secretário(a)");
        if (secretario != null) {
            System.out.println("ID = " + secretario.getId() + " NAME = " + secretario.getName());
        }

        Functionality horario = new Functionality("Horário Semanal", null, null, null);
        functionalityBO.create(horario);
        Functionality anos = new Functionality("Anos", horario, null, null);
        functionalityBO.create(anos);
        Functionality ano1 = new Functionality("1º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno1.getId(), null);
        functionalityBO.create(ano1);
        Functionality ano2 = new Functionality("2º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno2.getId(), null);
        functionalityBO.create(ano2);
        Functionality ano3 = new Functionality("3º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno3.getId(), null);
        functionalityBO.create(ano3);
        Functionality ano4 = new Functionality("4º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno4.getId(), null);
        functionalityBO.create(ano4);
        Functionality ano5 = new Functionality("5º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno5.getId(), null);
        functionalityBO.create(ano5);

        Functionality frequencia = new Functionality("Frequência", null, null, null);
        functionalityBO.create(frequencia);
        Functionality anosFrequencia = new Functionality("Anos", frequencia, null, null);
        functionalityBO.create(anosFrequencia);
        Functionality anoFrequencia1 = new Functionality("1º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno1.getId(), null);
        functionalityBO.create(anoFrequencia1);
        Functionality anoFrequencia2 = new Functionality("2º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno2.getId(), null);
        functionalityBO.create(anoFrequencia2);
        Functionality anoFrequencia3 = new Functionality("3º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno3.getId(), null);
        functionalityBO.create(anoFrequencia3);
        Functionality anoFrequencia4 = new Functionality("4º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno4.getId(), null);
        functionalityBO.create(anoFrequencia4);
        Functionality anoFrequencia5 = new Functionality("5º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno5.getId(), null);
        functionalityBO.create(anoFrequencia5);

        Functionality notas = new Functionality("Notas", null, null, null);
        functionalityBO.create(notas);
        Functionality anosNota = new Functionality("Anos", notas, null, null);
        functionalityBO.create(anosNota);
        Functionality anoNota1 = new Functionality("1º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization=" + orgAno1.getId(), null);
        functionalityBO.create(anoNota1);
        Functionality anoNota2 = new Functionality("2º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization=" + orgAno2.getId(), null);
        functionalityBO.create(anoNota2);
        Functionality anoNota3 = new Functionality("3º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization=" + orgAno3.getId(), null);
        functionalityBO.create(anoNota3);
        Functionality anoNota4 = new Functionality("4º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization=" + orgAno4.getId(), null);
        functionalityBO.create(anoNota4);
        Functionality anoNota5 = new Functionality("5º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization=" + orgAno5.getId(), null);
        functionalityBO.create(anoNota5);

        Grants grants01 = new Grants(ano1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants01);
        Grants grants02 = new Grants(ano2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants02);
        Grants grants03 = new Grants(ano3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants03);
        Grants grants04 = new Grants(ano4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants04);
        Grants grants05 = new Grants(ano5, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants05);

        Grants grants06 = new Grants(anoFrequencia1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants06);
        Grants grants07 = new Grants(anoFrequencia2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants07);
        Grants grants08 = new Grants(anoFrequencia3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants08);
        Grants grants09 = new Grants(anoFrequencia4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants09);
        Grants grants10 = new Grants(anoFrequencia5, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants10);

        Grants grants11 = new Grants(anoNota1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants11);
        Grants grants12 = new Grants(anoNota2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants12);
        Grants grants13 = new Grants(anoNota3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants13);
        Grants grants14 = new Grants(anoNota4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants14);
        Grants grants15 = new Grants(anoNota5, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants15);
    }

    public void finalInsert2() {
        Personage cefmin = personageBO.getPersonageByName("Coordenador(a) do Ensino Fundamental Menor");
        if (cefmin != null) {
            System.out.println("ID = " + cefmin.getId() + " NAME = " + cefmin.getName());
        }

        Personage cefmax = personageBO.getPersonageByName("Coordenador(a) do Ensino Fundamental Maior");
        if (cefmax != null) {
            System.out.println("ID = " + cefmax.getId() + " NAME = " + cefmax.getName());
        }

        Functionality plan = new Functionality("Planejamento", null, "/educational/registration/manageWorks.xhtml", null);
        functionalityBO.create(plan);

        Grants grants01 = new Grants(plan, null, cefmin.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants01);
        Grants grants02 = new Grants(plan, null, cefmax.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants02);
    }

    public void finalInsert3() {
//        disciplineBO.create(new Discipline("Estudos Sociais"));

        Organization fMaior = organizationBO.find(1100550161L);
        if (fMaior != null) {
            System.out.println("ID = " + fMaior.getId() + " NAME = " + fMaior.getName());
        }
        Organization orgAno6 = new Organization("6º Ano", "6º Ano", fMaior);
        Organization orgAno7 = new Organization("7º Ano", "7º Ano", fMaior);
        Organization orgAno8 = new Organization("8º Ano", "8º Ano", fMaior);
        Organization orgAno9 = new Organization("9º Ano", "9º Ano", fMaior);
        organizationBO.create(orgAno6);
        organizationBO.create(orgAno7);
        organizationBO.create(orgAno8);
        organizationBO.create(orgAno9);

        Personage secretario = personageBO.getPersonageByName("Secretário(a)");
        if (secretario != null) {
            System.out.println("ID = " + secretario.getId() + " NAME = " + secretario.getName());
        }

        Functionality anos = functionalityBO.find(-1319130075L);
        Functionality ano1 = new Functionality("6º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno6.getId(), null);
        functionalityBO.create(ano1);
        Functionality ano2 = new Functionality("7º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno7.getId(), null);
        functionalityBO.create(ano2);
        Functionality ano3 = new Functionality("8º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno8.getId(), null);
        functionalityBO.create(ano3);
        Functionality ano4 = new Functionality("9º Ano", anos, "/educational/schedule/unityschedule.xhtml?organizationID=" + orgAno9.getId(), null);
        functionalityBO.create(ano4);

        Functionality anosFrequencia = functionalityBO.find(75952643L);
        Functionality anoFrequencia1 = new Functionality("6º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno6.getId(), null);
        functionalityBO.create(anoFrequencia1);
        Functionality anoFrequencia2 = new Functionality("7º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno7.getId(), null);
        functionalityBO.create(anoFrequencia2);
        Functionality anoFrequencia3 = new Functionality("8º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno8.getId(), null);
        functionalityBO.create(anoFrequencia3);
        Functionality anoFrequencia4 = new Functionality("9º Ano", anosFrequencia, "/educational/frequency/simplefrequency.xhtml?organization=" + orgAno9.getId(), null);
        functionalityBO.create(anoFrequencia4);

//        Functionality anosNota = functionalityBO.find(-443010475L);
//        Functionality anoNota1 = new Functionality("6º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization="+orgAno6.getId(), null);
//        functionalityBO.create(anoNota1);
//        Functionality anoNota2 = new Functionality("7º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization="+orgAno7.getId(), null);
//        functionalityBO.create(anoNota2);
//        Functionality anoNota3 = new Functionality("8º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization="+orgAno8.getId(), null);
//        functionalityBO.create(anoNota3);
//        Functionality anoNota4 = new Functionality("9º Ano", anosNota, "/educational/performance/simpleperformance.xhtml?organization="+orgAno9.getId(), null);
//        functionalityBO.create(anoNota4);

        Functionality cads = functionalityBO.find(1722725456L);
        Functionality cad1 = new Functionality("6º Ano", cads, "/educational/registration/unityRegistration.xhtml?organization=" + orgAno6.getId() + "&type=0", null);
        functionalityBO.create(cad1);
        Functionality cad2 = new Functionality("7º Ano", cads, "/educational/registration/unityRegistration.xhtml?organization=" + orgAno7.getId() + "&type=0", null);
        functionalityBO.create(cad2);
        Functionality cad3 = new Functionality("8º Ano", cads, "/educational/registration/unityRegistration.xhtml?organization=" + orgAno8.getId() + "&type=0", null);
        functionalityBO.create(cad3);
        Functionality cad4 = new Functionality("9º Ano", cads, "/educational/registration/unityRegistration.xhtml?organization=" + orgAno9.getId() + "&type=0", null);
        functionalityBO.create(cad4);

        Functionality seas = functionalityBO.find(-1740578058L);
        Functionality sea1 = new Functionality("6º Ano", seas, "/educational/search/unitySearch.xhtml?organization=" + orgAno6.getId() + "&type=0", null);
        functionalityBO.create(sea1);
        Functionality sea2 = new Functionality("7º Ano", seas, "/educational/search/unitySearch.xhtml?organization=" + orgAno7.getId() + "&type=0", null);
        functionalityBO.create(sea2);
        Functionality sea3 = new Functionality("8º Ano", seas, "/educational/search/unitySearch.xhtml?organization=" + orgAno8.getId() + "&type=0", null);
        functionalityBO.create(sea3);
        Functionality sea4 = new Functionality("9º Ano", seas, "/educational/search/unitySearch.xhtml?organization=" + orgAno9.getId() + "&type=0", null);
        functionalityBO.create(sea4);

        Grants grants01 = new Grants(ano1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants01);
        Grants grants02 = new Grants(ano2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants02);
        Grants grants03 = new Grants(ano3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants03);
        Grants grants04 = new Grants(ano4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants04);

        Grants grants06 = new Grants(anoFrequencia1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants06);
        Grants grants07 = new Grants(anoFrequencia2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants07);
        Grants grants08 = new Grants(anoFrequencia3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants08);
        Grants grants09 = new Grants(anoFrequencia4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants09);

//        Grants grants11 = new Grants(anoNota1, null, secretario.getId(), null, 
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants11);
//        Grants grants12 = new Grants(anoNota2, null, secretario.getId(), null, 
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants12);
//        Grants grants13 = new Grants(anoNota3, null, secretario.getId(), null, 
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants13);
//        Grants grants14 = new Grants(anoNota4, null, secretario.getId(), null, 
//                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grants14);

        Grants grants15 = new Grants(cad1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants15);
        Grants grants16 = new Grants(cad2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants16);
        Grants grants17 = new Grants(cad3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants17);
        Grants grants18 = new Grants(cad4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants18);

        Grants grants19 = new Grants(sea1, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants19);
        Grants grants20 = new Grants(sea2, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants20);
        Grants grants21 = new Grants(sea3, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants21);
        Grants grants22 = new Grants(sea4, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grants22);
    }

    public void settleDatabase() {

        //CADASTRO DAS CONFIGURAÇÕES
        //Configurations configurations = new Configurations("serialnumber", "");
        //configurationsBO.create(configurations);

        Organization seed = new Organization("Secretaria da Educação", "SEED", null);
        organizationBO.create(seed);
        Organization creche = new Organization("CRECHE", "CRECHE", seed);
        organizationBO.create(creche);
        Organization coord = new Organization("Coordenações", "Coordenações", seed);
        organizationBO.create(coord);
        Organization supervisao = new Organization("Coordenação da Supervisão Escolar", "Supervisão Escolar", coord);
        organizationBO.create(supervisao);
        Organization coordpedag = new Organization("Coordenação Pedagógica", "Pedagógico", coord);
        organizationBO.create(coordpedag);
        Organization midias = new Organization("Coordenação de Mídias", "Mídias", coord);
        organizationBO.create(midias);
        Organization gestdemo = new Organization("Coordenação da Gestão Democrática", "Gestão Democrática", coord);
        organizationBO.create(gestdemo);
        Organization inf = new Organization("Coordenação da Educação Infantil", "Educação Infantil", coordpedag);
        organizationBO.create(inf);
        Organization fun1 = new Organization("Coordenação do Fundamental Menor", "Fundamental Menor", coordpedag);
        organizationBO.create(fun1);
        Organization fun2 = new Organization("Coordenação do Fundamental Maior", "Fundamental Maior", coordpedag);
        organizationBO.create(fun2);
        Organization eja = new Organization("Coordenação da Educação de Jovens e Adultos", "EJA", coordpedag);
        organizationBO.create(eja);
        Organization apee = new Organization("Coordenação das Atividades Pedagógicas", "APEE", coordpedag);
        organizationBO.create(apee);
        Organization conselhos = new Organization("Conselhos", "Conselhos", seed);
        organizationBO.create(conselhos);
        Organization fundeb = new Organization("Conselho do FUNDEB", "FUNDEB", conselhos);
        organizationBO.create(fundeb);
        Organization cae = new Organization("Conselho da Alimentação Escolar", "CAE", conselhos);
        organizationBO.create(cae);
        Organization conmesli = new Organization("Conselho Municipal da Educação de Santa Luzia do Itanhy", "CONMESLI", conselhos);
        organizationBO.create(conmesli);
        Organization unidadescolar = new Organization("Unidade Escolar", "Unidade Escolar", seed);
        organizationBO.create(unidadescolar);
        Organization escola = new Organization("Escola", "Escola", unidadescolar);
        organizationBO.create(escola);
        Organization conselho = new Organization("Conselho Escolar", "Conselho", unidadescolar);
        organizationBO.create(conselho);
        Organization setorpedag = new Organization("Setor Pedagógico", "Setor Pedagógico", escola);
        organizationBO.create(setorpedag);
        Organization setoradmin = new Organization("Setor Administrativo", "Setor Administrativo", escola);
        organizationBO.create(setoradmin);
        Organization infantil = new Organization("Infantil", "Infantil", setorpedag);
        organizationBO.create(infantil);
        Organization fundamental1 = new Organization("Fundamental Menor", "FI", setorpedag);
        organizationBO.create(fundamental1);
        Organization fundamental2 = new Organization("Fundamental Maior", "FII", setorpedag);
        organizationBO.create(fundamental2);
        Organization educjovad = new Organization("EJA", "EJA", setorpedag);
        organizationBO.create(educjovad);
        Organization serie1 = new Organization("1º Ano", "1º Ano", fundamental1);
        organizationBO.create(serie1);
        Organization serie2 = new Organization("2º Ano", "2º Ano", fundamental1);
        organizationBO.create(serie2);
        Organization serie3 = new Organization("3º Ano", "3º Ano", fundamental1);
        organizationBO.create(serie3);
        Organization serie4 = new Organization("4º Ano", "4º Ano", fundamental1);
        organizationBO.create(serie4);
        Organization serie5 = new Organization("5º Ano", "5º Ano", fundamental1);
        organizationBO.create(serie5);

        //Cadastro de Períodos
        Period integral = new Period("Integral");
        periodBO.create(integral);
        Period matutino = new Period("Matutino");
        periodBO.create(matutino);
        Period vespertino = new Period("Vespertino");
        periodBO.create(vespertino);
        Period noturno = new Period("Noturno");
        periodBO.create(noturno);

        //Cadastro de Personagens da rede educacional
        Personage secretarioEdu = new Personage("Secretário(a) da Educação", seed, PersonageType.MATRICULATED, null);
        personageBO.create(secretarioEdu);
        Personage secretarioAjd = new Personage("Secretário(a) Adjunto", seed, PersonageType.MATRICULATED, null);
        personageBO.create(secretarioAjd);
        Personage auxiliarAdministrativo = new Personage("Auxiliar Administrativo", seed, PersonageType.MATRICULATED, null);
        personageBO.create(auxiliarAdministrativo);

        Personage coordenadorSE = new Personage("Coordenador(a) da Supervisão Escolar", supervisao, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorSE);
        Personage coordenadorInf = new Personage("Coordenador(a) da Educação Infantil", inf, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorInf);
        Personage coordenadorFun1 = new Personage("Coordenador(a) do Ensino Fundamental Menor", fun1, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorFun1);
        Personage coordenadorFun2 = new Personage("Coordenador(a) do Ensino Fundamental Maior", fun2, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorFun2);
        Personage coordenadorEja = new Personage("Coordenador(a) do EJA", eja, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorEja);
        Personage coordenadorApee = new Personage("Coordenador(a) da Apee", apee, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorApee);
        Personage coordenadorGD = new Personage("Coordenador(a) da Gestão Democrática", gestdemo, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorGD);
        Personage coordenadorMidias = new Personage("Coordenador(a) de Mídias", midias, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorMidias);

        Personage presconmesli = new Personage("Presidente(a) da CONMESLI", conmesli, PersonageType.MATRICULATED, null);
        personageBO.create(presconmesli);
        Personage secconmesli = new Personage("Secretário(a) da CONMESLI", conmesli, PersonageType.MATRICULATED, null);
        personageBO.create(secconmesli);
        Personage memconmesli = new Personage("Membro(a) da CONMESLI", conmesli, PersonageType.MATRICULATED, null);
        personageBO.create(memconmesli);

        Personage presfundeb = new Personage("Presidente(a) do Conselho do FUNDEB", fundeb, PersonageType.MATRICULATED, null);
        personageBO.create(presfundeb);
        Personage secfundeb = new Personage("Secretário(a) do Conselho do FUNDEB", fundeb, PersonageType.MATRICULATED, null);
        personageBO.create(secfundeb);
        Personage memfundeb = new Personage("Membro(a) do Conselho do FUNDEB", fundeb, PersonageType.MATRICULATED, null);
        personageBO.create(memfundeb);

        Personage prescae = new Personage("Presidente(a) do CAE", cae, PersonageType.MATRICULATED, null);
        personageBO.create(prescae);
        Personage seccae = new Personage("Secretário(a) do CAE", cae, PersonageType.MATRICULATED, null);
        personageBO.create(seccae);
        Personage memcae = new Personage("Membro(a) do CAE", cae, PersonageType.MATRICULATED, null);
        personageBO.create(memcae);

        Personage presconsesc = new Personage("Presidente(a) do Conselho Escolar", conselho, PersonageType.MATRICULATED, null);
        personageBO.create(presconsesc);
        Personage secconsesc = new Personage("Secretário(a) do Conselho Escolar", conselho, PersonageType.MATRICULATED, null);
        personageBO.create(secconsesc);
        Personage memconsesc = new Personage("Membro(a) do Conselho Escolar", conselho, PersonageType.MATRICULATED, null);
        personageBO.create(memconsesc);

        Personage secretario = new Personage("Secretário(a)", unidadescolar, PersonageType.MATRICULATED, null);
        personageBO.create(secretario);
        Personage servente = new Personage("Servente", setoradmin, PersonageType.MATRICULATED, null);
        personageBO.create(servente);
        Personage merendeiro = new Personage("Merendeiro(a)", setoradmin, PersonageType.MATRICULATED, null);
        personageBO.create(merendeiro);
        Personage vigilante = new Personage("Vigiliante", setoradmin, PersonageType.MATRICULATED, null);
        personageBO.create(vigilante);
        Personage diretor = new Personage("Diretor(a)", setorpedag, PersonageType.MATRICULATED, null);
        personageBO.create(diretor);
        Personage coordenadorPedagogicoEscola = new Personage("Pedagogo", setorpedag, PersonageType.MATRICULATED, null);
        personageBO.create(coordenadorPedagogicoEscola);
        Personage professorEscola = new Personage("Professor(a)", setorpedag, PersonageType.MATRICULATED, null);
        personageBO.create(professorEscola);
        Personage professor1 = new Personage("Professor(a)", serie1, PersonageType.ALLOCATED, professorEscola);
        personageBO.create(professor1);
        Personage professor2 = new Personage("Professor(a)", serie2, PersonageType.ALLOCATED, professorEscola);
        personageBO.create(professor2);
        Personage professor3 = new Personage("Professor(a)", serie3, PersonageType.ALLOCATED, professorEscola);
        personageBO.create(professor3);
        Personage professor4 = new Personage("Professor(a)", serie4, PersonageType.ALLOCATED, professorEscola);
        personageBO.create(professor4);
        Personage professor5 = new Personage("Professor(a)", serie5, PersonageType.ALLOCATED, professorEscola);
        personageBO.create(professor5);
        Personage alunoEscola = new Personage("Aluno(a)", escola, PersonageType.MATRICULATED, null);
        personageBO.create(alunoEscola);
        Personage aluno1 = new Personage("Aluno(a)", serie1, PersonageType.MATRICULATED, alunoEscola);
        personageBO.create(aluno1);
        Personage aluno2 = new Personage("Aluno(a)", serie2, PersonageType.MATRICULATED, alunoEscola);
        personageBO.create(aluno2);
        Personage aluno3 = new Personage("Aluno(a)", serie3, PersonageType.MATRICULATED, alunoEscola);
        personageBO.create(aluno3);
        Personage aluno4 = new Personage("Aluno(a)", serie4, PersonageType.MATRICULATED, alunoEscola);
        personageBO.create(aluno4);
        Personage aluno5 = new Personage("Aluno(a)", serie5, PersonageType.MATRICULATED, alunoEscola);
        personageBO.create(aluno5);

        //Cadastro de Nationality
        Nationality brasileiro = new Nationality("BR", "BRASIL", "Brasileiro", "BRA", 76);
        nationalityBO.create(brasileiro);

        //Cadastro de Ethnicity
        Ethnicity negro = new Ethnicity("Negro");
        ethnicityBO.create(negro);
        Ethnicity branco = new Ethnicity("Branco");
        ethnicityBO.create(branco);
        Ethnicity indio = new Ethnicity("Índio");
        ethnicityBO.create(indio);
        Ethnicity pardo = new Ethnicity("Pardo");
        ethnicityBO.create(pardo);
        Ethnicity ethnicity = new Ethnicity("Não declarada");
        ethnicityBO.create(ethnicity);

        State state1 = new State("Sergipe", "SE");
        stateBO.create(state1);

        City city1 = new City("Santa Luzia do Itanhy", "Sta Luzia do Itanhy", null, state1);
        cityBO.create(city1);

        Neighborhood neighborhood1 = new Neighborhood("Getúlio Vargas", city1);
        neighborhoodBO.create(neighborhood1);
        Neighborhood neighborhood2 = new Neighborhood("Distrito Cajazeiras", city1);
        neighborhoodBO.create(neighborhood2);
        Neighborhood neighborhood3 = new Neighborhood("Povoado Tanque dos Bois", city1);
        neighborhoodBO.create(neighborhood3);
        Neighborhood neighborhood4 = new Neighborhood("Povoado Bode", city1);
        neighborhoodBO.create(neighborhood4);
        Neighborhood neighborhood5 = new Neighborhood("Povoado Taboa de Baixo", city1);
        neighborhoodBO.create(neighborhood5);
        Neighborhood neighborhood6 = new Neighborhood("Povoado Taboa de Cima", city1);
        neighborhoodBO.create(neighborhood6);
        Neighborhood neighborhood7 = new Neighborhood("Distrito Priapu I", city1);
        neighborhoodBO.create(neighborhood7);
        Neighborhood neighborhood8 = new Neighborhood("Distrito Priapu II", city1);
        neighborhoodBO.create(neighborhood8);
        Neighborhood neighborhood9 = new Neighborhood("Povoado Pau Torto I", city1);
        neighborhoodBO.create(neighborhood9);
        Neighborhood neighborhood10 = new Neighborhood("Povoado Pau Torto II", city1);
        neighborhoodBO.create(neighborhood10);
        Neighborhood neighborhood11 = new Neighborhood("Assentamento São José", city1);
        neighborhoodBO.create(neighborhood11);
        Neighborhood neighborhood12 = new Neighborhood("Assentamento Palha", city1);
        neighborhoodBO.create(neighborhood12);
        Neighborhood neighborhood13 = new Neighborhood("Distrito Crasto", city1);
        neighborhoodBO.create(neighborhood13);
        Neighborhood neighborhood14 = new Neighborhood("Distrito Rua da Palha", city1);
        neighborhoodBO.create(neighborhood14);
        Neighborhood neighborhood15 = new Neighborhood("Povoado Pedra Furada", city1);
        neighborhoodBO.create(neighborhood15);
        Neighborhood neighborhood16 = new Neighborhood("Distrito Areia Branca", city1);
        neighborhoodBO.create(neighborhood16);
        Neighborhood neighborhood17 = new Neighborhood("Povoado Maliça", city1);
        neighborhoodBO.create(neighborhood17);
        Neighborhood neighborhood18 = new Neighborhood("Povoado Mocambo", city1);
        neighborhoodBO.create(neighborhood18);
        Neighborhood neighborhood19 = new Neighborhood("Povoado Retiro", city1);
        neighborhoodBO.create(neighborhood19);
        Neighborhood neighborhood20 = new Neighborhood("Povoado Bomfim", city1);
        neighborhoodBO.create(neighborhood20);
        Neighborhood neighborhood21 = new Neighborhood("Povoado Catruz", city1);
        neighborhoodBO.create(neighborhood21);
        Neighborhood neighborhood22 = new Neighborhood("Povoado Gonçala", city1);
        neighborhoodBO.create(neighborhood22);
        Neighborhood neighborhood23 = new Neighborhood("Povoado Feirinha", city1);
        neighborhoodBO.create(neighborhood23);
        Neighborhood neighborhood24 = new Neighborhood("Povoado Murici", city1);
        neighborhoodBO.create(neighborhood24);
        Neighborhood neighborhood25 = new Neighborhood("Distrito Piçarreira", city1);
        neighborhoodBO.create(neighborhood25);
        Neighborhood neighborhood26 = new Neighborhood("Povoado Novo Jardim", city1);
        neighborhoodBO.create(neighborhood26);
        Neighborhood neighborhood27 = new Neighborhood("Povoado Imbé", city1);
        neighborhoodBO.create(neighborhood27);
        Neighborhood neighborhood28 = new Neighborhood("Povoado Riacho do Marco", city1);
        neighborhoodBO.create(neighborhood28);
        Neighborhood neighborhood29 = new Neighborhood("Povoado Campo de Nossa Senhora", city1);
        neighborhoodBO.create(neighborhood29);
        Neighborhood neighborhood30 = new Neighborhood("Distrito Botequim", city1);
        neighborhoodBO.create(neighborhood30);
        Neighborhood neighborhood31 = new Neighborhood("Povoado Piaçava", city1);
        neighborhoodBO.create(neighborhood31);
        Neighborhood neighborhood32 = new Neighborhood("Povoado Baltazar", city1);
        neighborhoodBO.create(neighborhood32);
        Neighborhood neighborhood33 = new Neighborhood("Povoado Mangabeira", city1);
        neighborhoodBO.create(neighborhood33);
        Neighborhood neighborhood34 = new Neighborhood("Povoado Coqueiro", city1);
        neighborhoodBO.create(neighborhood34);
        Neighborhood neighborhood35 = new Neighborhood("Assentamento Cleonice Alves", city1);
        neighborhoodBO.create(neighborhood35);
        Neighborhood neighborhood36 = new Neighborhood("Povoado Caititu", city1);
        neighborhoodBO.create(neighborhood36);
        Neighborhood neighborhood37 = new Neighborhood("Fazenda Cedro", city1);
        neighborhoodBO.create(neighborhood37);
        Neighborhood neighborhood38 = new Neighborhood("Fazenda Antas", city1);
        neighborhoodBO.create(neighborhood38);
        Neighborhood neighborhood39 = new Neighborhood("Fazenda São Felix", city1);
        neighborhoodBO.create(neighborhood39);
        Neighborhood neighborhood40 = new Neighborhood("Povoado Bom Viver", city1);
        neighborhoodBO.create(neighborhood40);

        Street street1 = new Street("Rua A", city1);
        streetBO.create(street1);

        Zipcode zipcode1 = new Zipcode(49230000, city1, null, null);
        zipcodeBO.create(zipcode1);
        Address enderecoSEEDSLI = new Address(null, null, neighborhood1, street1, zipcode1);
        addressBO.create(enderecoSEEDSLI);

        //Cadastro de Juridic
        Juridic juridicSEEDSLI = new Juridic("Secretaria Municipal de Educação de Santa Luzia do Itanhi", "SEMESLI", null, "(79)3548-1431", null, enderecoSEEDSLI, Calendar.getInstance(), brasileiro);
        juridicBO.create(juridicSEEDSLI);

        //Cadastro de Unity
        Unity seedSLI = new Unity("Secretaria Municipal de Educação de Santa Luzia do Itanhi", (short) 0, Calendar.getInstance(), null, seed, null, integral, juridicSEEDSLI);
        unityBO.create(seedSLI);

        Unity coordenacoes = new Unity("Coordenações", (short) 0, Calendar.getInstance(), null, coord, seedSLI, integral, null);
        unityBO.create(coordenacoes);

        Unity coordMidias = new Unity("Coordenação de Mídias", (short) 0, Calendar.getInstance(), null, midias, coordenacoes, integral, null);
        unityBO.create(coordMidias);
        Unity coordSuper = new Unity("Coordenação da Supervisão Escolar", (short) 0, Calendar.getInstance(), null, supervisao, coordenacoes, integral, null);
        unityBO.create(coordSuper);
        Unity coordGestDemo = new Unity("Coordenação da Gestão Democrática", (short) 0, Calendar.getInstance(), null, gestdemo, coordenacoes, integral, null);
        unityBO.create(coordGestDemo);
        Unity coordPedag = new Unity("Coordenação Pedagógica", (short) 0, Calendar.getInstance(), null, coordpedag, coordenacoes, integral, null);
        unityBO.create(coordPedag);

        Unity coordInf = new Unity("Coordenação do Infantil", (short) 0, Calendar.getInstance(), null, inf, coordPedag, integral, null);
        unityBO.create(coordInf);
        Unity coordFun1 = new Unity("Coordenação do Fundamental I", (short) 0, Calendar.getInstance(), null, fun1, coordPedag, integral, null);
        unityBO.create(coordFun1);
        Unity coordFun2 = new Unity("Coordenação do Fundamental II", (short) 0, Calendar.getInstance(), null, fun2, coordPedag, integral, null);
        unityBO.create(coordFun2);
        Unity coordEja = new Unity("Coordenação do EJA", (short) 0, Calendar.getInstance(), null, eja, coordPedag, integral, null);
        unityBO.create(coordEja);
        Unity coordApee = new Unity("Coordenação da Apee", (short) 0, Calendar.getInstance(), null, apee, coordPedag, integral, null);
        unityBO.create(coordApee);

        Unity unidadeConselhos = new Unity("Conselhos", (short) 0, Calendar.getInstance(), null, conselhos, seedSLI, integral, null);
        unityBO.create(unidadeConselhos);

        Unity consCae = new Unity("Conselho da Alimentação Escolar", (short) 0, Calendar.getInstance(), null, cae, unidadeConselhos, integral, null);
        unityBO.create(consCae);
        Unity consFundeb = new Unity("Fundeb", (short) 0, Calendar.getInstance(), null, fundeb, unidadeConselhos, integral, null);
        unityBO.create(consFundeb);
        Unity consConmesli = new Unity("Conmesli", (short) 0, Calendar.getInstance(), null, conmesli, unidadeConselhos, integral, null);
        unityBO.create(consConmesli);

        //Cadastro de Address, Human, Actor e Login
        Human admin = new Human("Administrador", "Admin", "seuemail@email.com", "(79)3333-3333", "(79)9999-9999", enderecoSEEDSLI, Calendar.getInstance(), brasileiro, Sex.MALE, Laterality.RightHanded, MaritalStatus.Single, negro, null, null, null);
        humanBO.create(admin);
        Actor actorAdmin = new Actor(Calendar.getInstance(), null, admin, seedSLI, auxiliarAdministrativo);
        actorBO.create(actorAdmin);
        Login loginAdmin = new Login("admin", EncryptionUtil.encrypt("admin"), admin);
        loginBO.create(loginAdmin);

        //Cadastro de tipos de informações adicionais
        AdditionalInfoType cpf = new AdditionalInfoType("CPF", "Cadastro de Pessoa Física", "999.999.999-99", (short) 1);
        additionalInfoTypeBO.create(cpf);
        AdditionalInfoType rg = new AdditionalInfoType("RG", "Registro Geral", null, (short) 2);
        additionalInfoTypeBO.create(rg);
        AdditionalInfoType nis = new AdditionalInfoType("NIS", "Número de Identificação Social", null, (short) 3);
        additionalInfoTypeBO.create(nis);
        AdditionalInfoType cnpj = new AdditionalInfoType("CNPJ", "Cadastro Nacional de Pessoa Jurídica", "99.999.999/9999-99", (short) 1);
        additionalInfoTypeBO.create(cnpj);

        //Associação dos tipos com os personagens
        AddInfoPersonage cpfSecEdu = new AddInfoPersonage(secretarioEdu, cpf);
        addInfoPersonageBO.create(cpfSecEdu);
        AddInfoPersonage cpfSecAdj = new AddInfoPersonage(secretarioAjd, cpf);
        addInfoPersonageBO.create(cpfSecAdj);
        AddInfoPersonage cpfAuxAdmin = new AddInfoPersonage(auxiliarAdministrativo, cpf);
        addInfoPersonageBO.create(cpfAuxAdmin);
        AddInfoPersonage cpfCoordSE = new AddInfoPersonage(coordenadorSE, cpf);
        addInfoPersonageBO.create(cpfCoordSE);
        AddInfoPersonage cpfCoordInf = new AddInfoPersonage(coordenadorInf, cpf);
        addInfoPersonageBO.create(cpfCoordInf);
        AddInfoPersonage cpfCoordFun1 = new AddInfoPersonage(coordenadorFun1, cpf);
        addInfoPersonageBO.create(cpfCoordFun1);
        AddInfoPersonage cpfCoordFun2 = new AddInfoPersonage(coordenadorFun2, cpf);
        addInfoPersonageBO.create(cpfCoordFun2);
        AddInfoPersonage cpfCoordEja = new AddInfoPersonage(coordenadorEja, cpf);
        addInfoPersonageBO.create(cpfCoordEja);
        AddInfoPersonage cpfCoordApee = new AddInfoPersonage(coordenadorApee, cpf);
        addInfoPersonageBO.create(cpfCoordApee);
        AddInfoPersonage cpfCoordGD = new AddInfoPersonage(coordenadorGD, cpf);
        addInfoPersonageBO.create(cpfCoordGD);
        AddInfoPersonage cpfCoorMid = new AddInfoPersonage(coordenadorMidias, cpf);
        addInfoPersonageBO.create(cpfCoorMid);
        AddInfoPersonage rgSecEdu = new AddInfoPersonage(secretarioEdu, rg);
        addInfoPersonageBO.create(rgSecEdu);
        AddInfoPersonage rgSecAdj = new AddInfoPersonage(secretarioAjd, rg);
        addInfoPersonageBO.create(rgSecAdj);
        AddInfoPersonage rgAuxAdmin = new AddInfoPersonage(auxiliarAdministrativo, rg);
        addInfoPersonageBO.create(rgAuxAdmin);
        AddInfoPersonage rgCoordSE = new AddInfoPersonage(coordenadorSE, rg);
        addInfoPersonageBO.create(rgCoordSE);
        AddInfoPersonage rgCoordInf = new AddInfoPersonage(coordenadorInf, rg);
        addInfoPersonageBO.create(rgCoordInf);
        AddInfoPersonage rgCoordFun1 = new AddInfoPersonage(coordenadorFun1, rg);
        addInfoPersonageBO.create(rgCoordFun1);
        AddInfoPersonage rgCoordFun2 = new AddInfoPersonage(coordenadorFun2, rg);
        addInfoPersonageBO.create(rgCoordFun2);
        AddInfoPersonage rgCoordEja = new AddInfoPersonage(coordenadorEja, rg);
        addInfoPersonageBO.create(rgCoordEja);
        AddInfoPersonage rgCoordApee = new AddInfoPersonage(coordenadorApee, rg);
        addInfoPersonageBO.create(rgCoordApee);
        AddInfoPersonage rgCoordGD = new AddInfoPersonage(coordenadorGD, rg);
        addInfoPersonageBO.create(rgCoordGD);
        AddInfoPersonage rgCoorMid = new AddInfoPersonage(coordenadorMidias, rg);
        addInfoPersonageBO.create(rgCoorMid);

        AddInfoPersonage cpfpresconmesli = new AddInfoPersonage(presconmesli, cpf);
        addInfoPersonageBO.create(cpfpresconmesli);
        AddInfoPersonage cpfsecconmesli = new AddInfoPersonage(secconmesli, cpf);
        addInfoPersonageBO.create(cpfsecconmesli);
        AddInfoPersonage cpfmemconmesli = new AddInfoPersonage(memconmesli, cpf);
        addInfoPersonageBO.create(cpfmemconmesli);
        AddInfoPersonage cpfpresfundeb = new AddInfoPersonage(presfundeb, cpf);
        addInfoPersonageBO.create(cpfpresfundeb);
        AddInfoPersonage cpfsecfundeb = new AddInfoPersonage(secfundeb, cpf);
        addInfoPersonageBO.create(cpfsecfundeb);
        AddInfoPersonage cpfmemfundeb = new AddInfoPersonage(memfundeb, cpf);
        addInfoPersonageBO.create(cpfmemfundeb);
        AddInfoPersonage cpfprescae = new AddInfoPersonage(prescae, cpf);
        addInfoPersonageBO.create(cpfprescae);
        AddInfoPersonage cpfseccae = new AddInfoPersonage(seccae, cpf);
        addInfoPersonageBO.create(cpfseccae);
        AddInfoPersonage cpfmemcae = new AddInfoPersonage(memcae, cpf);
        addInfoPersonageBO.create(cpfmemcae);
        AddInfoPersonage rgpresconmesli = new AddInfoPersonage(presconmesli, rg);
        addInfoPersonageBO.create(rgpresconmesli);
        AddInfoPersonage rgsecconmesli = new AddInfoPersonage(secconmesli, rg);
        addInfoPersonageBO.create(rgsecconmesli);
        AddInfoPersonage rgmemconmesli = new AddInfoPersonage(memconmesli, rg);
        addInfoPersonageBO.create(rgmemconmesli);
        AddInfoPersonage rgpresfundeb = new AddInfoPersonage(presfundeb, rg);
        addInfoPersonageBO.create(rgpresfundeb);
        AddInfoPersonage rgsecfundeb = new AddInfoPersonage(secfundeb, rg);
        addInfoPersonageBO.create(rgsecfundeb);
        AddInfoPersonage rgmemfundeb = new AddInfoPersonage(memfundeb, rg);
        addInfoPersonageBO.create(rgmemfundeb);
        AddInfoPersonage rgprescae = new AddInfoPersonage(prescae, rg);
        addInfoPersonageBO.create(rgprescae);
        AddInfoPersonage rgseccae = new AddInfoPersonage(seccae, rg);
        addInfoPersonageBO.create(rgseccae);
        AddInfoPersonage rgmemcae = new AddInfoPersonage(memcae, rg);
        addInfoPersonageBO.create(rgmemcae);

        AddInfoPersonage cpfpresconsesc = new AddInfoPersonage(presconsesc, cpf);
        addInfoPersonageBO.create(cpfpresconsesc);
        AddInfoPersonage cpfsecconsesc = new AddInfoPersonage(secconsesc, cpf);
        addInfoPersonageBO.create(cpfsecconsesc);
        AddInfoPersonage cpfmemconsesc = new AddInfoPersonage(memconsesc, cpf);
        addInfoPersonageBO.create(cpfmemconsesc);
        AddInfoPersonage rgpresconsesc = new AddInfoPersonage(presconsesc, rg);
        addInfoPersonageBO.create(rgpresconsesc);
        AddInfoPersonage rgsecconsesc = new AddInfoPersonage(secconsesc, rg);
        addInfoPersonageBO.create(rgsecconsesc);
        AddInfoPersonage rgmemconsesc = new AddInfoPersonage(memconsesc, rg);
        addInfoPersonageBO.create(rgmemconsesc);


        AddInfoPersonage cpfDiretor = new AddInfoPersonage(diretor, cpf);
        addInfoPersonageBO.create(cpfDiretor);
        AddInfoPersonage cpfSecretario = new AddInfoPersonage(secretario, cpf);
        addInfoPersonageBO.create(cpfSecretario);
        AddInfoPersonage cpfCoorPedEscola = new AddInfoPersonage(coordenadorPedagogicoEscola, cpf);
        addInfoPersonageBO.create(cpfCoorPedEscola);
        AddInfoPersonage cpfProfessor = new AddInfoPersonage(professorEscola, cpf);
        addInfoPersonageBO.create(cpfProfessor);
        AddInfoPersonage cpfservente = new AddInfoPersonage(servente, cpf);
        addInfoPersonageBO.create(cpfservente);
        AddInfoPersonage cpfmerendeiro = new AddInfoPersonage(merendeiro, cpf);
        addInfoPersonageBO.create(cpfmerendeiro);
        AddInfoPersonage cpfvigilante = new AddInfoPersonage(vigilante, cpf);
        addInfoPersonageBO.create(cpfvigilante);
        AddInfoPersonage rgDiretor = new AddInfoPersonage(diretor, rg);
        addInfoPersonageBO.create(rgDiretor);
        AddInfoPersonage rgSecretario = new AddInfoPersonage(secretario, rg);
        addInfoPersonageBO.create(rgSecretario);
        AddInfoPersonage rgCoorPedEscola = new AddInfoPersonage(coordenadorPedagogicoEscola, rg);
        addInfoPersonageBO.create(rgCoorPedEscola);
        AddInfoPersonage rgProfessor = new AddInfoPersonage(professorEscola, rg);
        addInfoPersonageBO.create(rgProfessor);
        AddInfoPersonage rgservente = new AddInfoPersonage(servente, rg);
        addInfoPersonageBO.create(rgservente);
        AddInfoPersonage rgmerendeiro = new AddInfoPersonage(merendeiro, rg);
        addInfoPersonageBO.create(rgmerendeiro);
        AddInfoPersonage rgvigilante = new AddInfoPersonage(vigilante, rg);
        addInfoPersonageBO.create(rgvigilante);

        AddInfoPersonage nisAluno = new AddInfoPersonage(alunoEscola, nis);
        addInfoPersonageBO.create(nisAluno);
        AddInfoPersonage cnpjUnidade = new AddInfoPersonage(null, cnpj);
        addInfoPersonageBO.create(cnpjUnidade);

        //Cadastro de disciplinas
        Discipline d1 = new Discipline("Português");
        disciplineBO.create(d1);
        Discipline d2 = new Discipline("Matemática");
        disciplineBO.create(d2);
        Discipline d3 = new Discipline("História");
        disciplineBO.create(d3);
        Discipline d4 = new Discipline("Geografia");
        disciplineBO.create(d4);
        Discipline d5 = new Discipline("Redação");
        disciplineBO.create(d5);

        //Cadastro de seasons
        Season s1 = new Season("1° Bimestre");
        seasonBO.create(s1);
        Season s2 = new Season("2° Bimestre");
        seasonBO.create(s2);
        Season s3 = new Season("3° Bimestre");
        seasonBO.create(s3);
        Season s4 = new Season("4° Bimestre");
        seasonBO.create(s4);

        //cadastro de questionários
        Questions question1 = new Questions("Peso & Altura", false);
        questionsBO.create(question1);
        Questions question2 = new Questions("Hb", true);
        questionsBO.create(question2);

        //cadastro de perguntas dos questionários
        Asks ask1 = new Asks("Peso", AskTypes.Inserted, "kg", null, question1);
        askBO.create(ask1);
        Asks ask2 = new Asks("Altura", AskTypes.Inserted, "m", null, question1);
        askBO.create(ask2);
        Asks ask3 = new Asks("Hb", AskTypes.Inserted, "g/dl", null, question2);
        askBO.create(ask3);


        //cadastro de funcionalidade
        Functionality cadastro = new Functionality("Cadastro", null, null, null);
        functionalityBO.create(cadastro);
        Functionality cadastroUnidade = new Functionality("Unidade", cadastro, null, null);
        functionalityBO.create(cadastroUnidade);
        Functionality cadastroAtor = new Functionality("Ator", cadastro, null, null);
        functionalityBO.create(cadastroAtor);

        Functionality cadastroNovaPessoa = new Functionality("Nova Pessoa", cadastroAtor, null, null);
        functionalityBO.create(cadastroNovaPessoa);
        Functionality cadastroPessoaExistente = new Functionality("Pessoa Existente", cadastroAtor, null, null);
        functionalityBO.create(cadastroPessoaExistente);

        Functionality buscar = new Functionality("Consultar", null, null, null);
        functionalityBO.create(buscar);
        Functionality buscarUnidade = new Functionality("Unidade", buscar, null, null);
        functionalityBO.create(buscarUnidade);
        Functionality buscarAtor = new Functionality("Ator", buscar, null, null);
        functionalityBO.create(buscarAtor);

        Functionality cadastroCoordenacoes = new Functionality("Coordenações", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroCoordenacoes);
        Functionality cadastroCoordenacoes2 = new Functionality("Coordenações", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroCoordenacoes2);
        Functionality buscarCoordenacoes = new Functionality("Coordenações", buscarAtor, null, null);
        functionalityBO.create(buscarCoordenacoes);

        Functionality cadastroPedagogica = new Functionality("Pedagógica", cadastroCoordenacoes, null, null);
        functionalityBO.create(cadastroPedagogica);
        Functionality cadastroPedagogica2 = new Functionality("Pedagógica", cadastroCoordenacoes2, null, null);
        functionalityBO.create(cadastroPedagogica2);
        Functionality buscarPedagogica = new Functionality("Pedagógica", buscarCoordenacoes, null, null);
        functionalityBO.create(buscarPedagogica);

        Functionality cadastroConselhos = new Functionality("Conselhos", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroConselhos);
        Functionality cadastroConselhos2 = new Functionality("Conselhos", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroConselhos2);
        Functionality buscarConselhos = new Functionality("Conselhos", buscarAtor, null, null);
        functionalityBO.create(buscarConselhos);

        Functionality cadastroCAE = new Functionality("CAE", cadastroConselhos, null, null);
        functionalityBO.create(cadastroCAE);
        Functionality cadastroCAE2 = new Functionality("CAE", cadastroConselhos2, null, null);
        functionalityBO.create(cadastroCAE2);
        Functionality buscarCAE = new Functionality("CAE", buscarConselhos, null, null);
        functionalityBO.create(buscarCAE);

        Functionality cadastroFundeb = new Functionality("FUNDEB", cadastroConselhos, null, null);
        functionalityBO.create(cadastroFundeb);
        Functionality cadastroFundeb2 = new Functionality("FUNDEB", cadastroConselhos2, null, null);
        functionalityBO.create(cadastroFundeb2);
        Functionality buscarFundeb = new Functionality("FUNDEB", buscarConselhos, null, null);
        functionalityBO.create(buscarFundeb);

        Functionality cadastroConmesli = new Functionality("CONMESLI", cadastroConselhos, null, null);
        functionalityBO.create(cadastroConmesli);
        Functionality cadastroConmesli2 = new Functionality("CONMESLI", cadastroConselhos2, null, null);
        functionalityBO.create(cadastroConmesli2);
        Functionality buscarConmesli = new Functionality("CONMESLI", buscarConselhos, null, null);
        functionalityBO.create(buscarConmesli);

        Functionality cadastroUnidEscolar = new Functionality("Unidade Escolar", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroUnidEscolar);
        Functionality cadastroUnidEscolar2 = new Functionality("Unidade Escolar", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroUnidEscolar2);
        Functionality buscarUnidEscolar = new Functionality("Unidade Escolar", buscarAtor, null, null);
        functionalityBO.create(buscarUnidEscolar);

        Functionality cadastroSetorPed = new Functionality("Setor Pedagógico", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroSetorPed);
        Functionality cadastroSetorPed2 = new Functionality("Setor Pedagógico", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroSetorPed2);
        Functionality buscarSetorPed = new Functionality("Setor Pedagógico", buscarAtor, null, null);
        functionalityBO.create(buscarSetorPed);

        Functionality cadastroSetorAdm = new Functionality("Setor Administrativo", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroSetorAdm);
        Functionality cadastroSetorAdm2 = new Functionality("Setor Administrativo", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroSetorAdm2);
        Functionality buscarSetorAdm = new Functionality("Setor Administrativo", buscarAtor, null, null);
        functionalityBO.create(buscarSetorAdm);

        Functionality cadastroEscolaPessoa = new Functionality("Escola", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroEscolaPessoa);
        Functionality cadastroEscolaPessoa2 = new Functionality("Escola", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroEscolaPessoa2);
        Functionality buscarEscolaPessoa = new Functionality("Escola", buscarAtor, null, null);
        functionalityBO.create(buscarEscolaPessoa);

        Functionality cadastroSec = new Functionality("Secretaria", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroSec);
        Functionality cadastroSec2 = new Functionality("Secretaria", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroSec2);
        Functionality buscarSec = new Functionality("Secretaria", buscarAtor, null, null);
        functionalityBO.create(buscarSec);

        Functionality cadastroConselhoEscola = new Functionality("Conselho", cadastroNovaPessoa, null, null);
        functionalityBO.create(cadastroConselhoEscola);
        Functionality cadastroConselhoEscola2 = new Functionality("Conselho", cadastroPessoaExistente, null, null);
        functionalityBO.create(cadastroConselhoEscola2);
        Functionality buscarConselhoEscola = new Functionality("Conselho", buscarAtor, null, null);
        functionalityBO.create(buscarConselhoEscola);

        Functionality cadastroAnos = new Functionality("Anos", cadastroUnidade, null, null);
        functionalityBO.create(cadastroAnos);
        Functionality buscarAnos = new Functionality("Anos", buscarUnidade, null, null);
        functionalityBO.create(buscarAnos);

        Functionality cadastroPlanos = new Functionality("Planos", null, null, null);
        functionalityBO.create(cadastroPlanos);

        Functionality notasFrequencias = new Functionality("Notas e Frequências", null, null, null);
        functionalityBO.create(notasFrequencias);

        Functionality notasFrequenciasInfantil = new Functionality("Infantil", notasFrequencias, "/educational/performance/performance.xhtml?organization=" + infantil.getId(), null);
        functionalityBO.create(notasFrequenciasInfantil);
        Functionality notasFrequenciasFund1 = new Functionality("Fundamental I", notasFrequencias, "/educational/performance/performance.xhtml?organization=" + fundamental1.getId(), null);
        functionalityBO.create(notasFrequenciasFund1);
        Functionality notasFrequenciasFund2 = new Functionality("Fundamental II", notasFrequencias, "/educational/performance/performance.xhtml?organization=" + fundamental2.getId(), null);
        functionalityBO.create(notasFrequenciasFund2);

        Functionality matricula = new Functionality("Matrícula", null, null, null);
        functionalityBO.create(matricula);

        Functionality matriculaALuno = new Functionality("Aluno", matricula, "/educational/enrollment/enrollment.xhtml?personage=" + alunoEscola.getId(), null);
        functionalityBO.create(matriculaALuno);

        Functionality cadastroPlanoOrganizacao = new Functionality("Cadastrar", cadastroPlanos, "/educational/plans/createOrganizationPlans.xhtml", null);
        functionalityBO.create(cadastroPlanoOrganizacao);
        Functionality buscarPlanoOrganizacao = new Functionality("Buscar", cadastroPlanos, "/educational/plans/viewPlans.xhtml", null);
        functionalityBO.create(buscarPlanoOrganizacao);

        Functionality cadastroUnidadeEscolar = new Functionality("Unidade Escolar", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + unidadescolar.getId() + "&type=0", null);
        functionalityBO.create(cadastroUnidadeEscolar);
        Functionality cadastroEscola = new Functionality("Escola", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + escola.getId() + "&type=1", null);
        functionalityBO.create(cadastroEscola);
        Functionality cadastroconselho = new Functionality("Conselho Escolar", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + conselho.getId() + "&type=1", null);
        functionalityBO.create(cadastroconselho);
        Functionality cadastrosetorpedag = new Functionality("Setor Pedagógico", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + setorpedag.getId() + "&type=0", null);
        functionalityBO.create(cadastrosetorpedag);
        Functionality cadastrosetoradmin = new Functionality("Setor Administrativo", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + setoradmin.getId() + "&type=0", null);
        functionalityBO.create(cadastrosetoradmin);
        Functionality cadastroinfantil = new Functionality("Infantil", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + infantil.getId() + "&type=0", null);
        functionalityBO.create(cadastroinfantil);
        Functionality cadastrofundamental1 = new Functionality("Fundamental Menor", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + fundamental1.getId() + "&type=0", null);
        functionalityBO.create(cadastrofundamental1);
        Functionality cadastrofundamental2 = new Functionality("Fundamental Maior", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + fundamental2.getId() + "&type=0", null);
        functionalityBO.create(cadastrofundamental2);
        Functionality cadastroeducjovad = new Functionality("EJA", cadastroUnidade, "/educational/registration/unityRegistration.xhtml?organization=" + educjovad.getId() + "&type=0", null);
        functionalityBO.create(cadastroeducjovad);
        Functionality cadastroSerie1 = new Functionality("1º Ano", cadastroAnos, "/educational/registration/unityRegistration.xhtml?organization=" + serie1.getId() + "&type=0", null);
        functionalityBO.create(cadastroSerie1);
        Functionality cadastroSerie2 = new Functionality("2º Ano", cadastroAnos, "/educational/registration/unityRegistration.xhtml?organization=" + serie2.getId() + "&type=0", null);
        functionalityBO.create(cadastroSerie2);
        Functionality cadastroSerie3 = new Functionality("3º Ano", cadastroAnos, "/educational/registration/unityRegistration.xhtml?organization=" + serie3.getId() + "&type=0", null);
        functionalityBO.create(cadastroSerie3);
        Functionality cadastroSerie4 = new Functionality("4º Ano", cadastroAnos, "/educational/registration/unityRegistration.xhtml?organization=" + serie4.getId() + "&type=0", null);
        functionalityBO.create(cadastroSerie4);
        Functionality cadastroSerie5 = new Functionality("5º Ano", cadastroAnos, "/educational/registration/unityRegistration.xhtml?organization=" + serie5.getId() + "&type=0", null);
        functionalityBO.create(cadastroSerie5);

        Functionality cadastroSecEdu = new Functionality("Secretário da Educação", cadastroSec, "/educational/registration/actorRegistration.xhtml?personage=" + secretarioEdu.getId(), null);
        functionalityBO.create(cadastroSecEdu);
        Functionality cadastroSecEdu2 = new Functionality("Secretário da Educação", cadastroSec2, "/educational/registration/newActorForHuman.xhtml?personage=" + secretarioEdu.getId(), null);
        functionalityBO.create(cadastroSecEdu2);
        Functionality cadastrosecretarioAjd = new Functionality("Secretário Adjunto", cadastroSec, "/educational/registration/actorRegistration.xhtml?personage=" + secretarioAjd.getId(), null);
        functionalityBO.create(cadastrosecretarioAjd);
        Functionality cadastrosecretarioAjd2 = new Functionality("Secretário Adjunto", cadastroSec2, "/educational/registration/newActorForHuman.xhtml?personage=" + secretarioAjd.getId(), null);
        functionalityBO.create(cadastrosecretarioAjd2);
        Functionality cadastroauxiliarAdministrativo = new Functionality("Auxiliar Administrativo", cadastroSec, "/educational/registration/actorRegistration.xhtml?personage=" + auxiliarAdministrativo.getId(), null);
        functionalityBO.create(cadastroauxiliarAdministrativo);
        Functionality cadastroauxiliarAdministrativo2 = new Functionality("Auxiliar Administrativo", cadastroSec2, "/educational/registration/newActorForHuman.xhtml?personage=" + auxiliarAdministrativo.getId(), null);
        functionalityBO.create(cadastroauxiliarAdministrativo2);

        Functionality cadastroCoorMid = new Functionality("Coordenador de Mídias", cadastroCoordenacoes, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorMidias.getId(), null);
        functionalityBO.create(cadastroCoorMid);
        Functionality cadastroCoorMid2 = new Functionality("Coordenador de Mídias", cadastroCoordenacoes2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorMidias.getId(), null);
        functionalityBO.create(cadastroCoorMid2);
        Functionality cadastroCoorInf = new Functionality("Coordenador do Infantil", cadastroPedagogica, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorInf.getId(), null);
        functionalityBO.create(cadastroCoorInf);
        Functionality cadastroCoorInf2 = new Functionality("Coordenador do Infantil", cadastroPedagogica2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorInf.getId(), null);
        functionalityBO.create(cadastroCoorInf2);
        Functionality cadastroCoorFun1 = new Functionality("Coordenador do Fundamental I", cadastroPedagogica, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorFun1.getId(), null);
        functionalityBO.create(cadastroCoorFun1);
        Functionality cadastroCoorFun12 = new Functionality("Coordenador do Fundamental I", cadastroPedagogica2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorFun1.getId(), null);
        functionalityBO.create(cadastroCoorFun12);
        Functionality cadastroCoorFun2 = new Functionality("Coordenador do Fundamental II", cadastroPedagogica, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorFun2.getId(), null);
        functionalityBO.create(cadastroCoorFun2);
        Functionality cadastroCoorFun22 = new Functionality("Coordenador do Fundamental II", cadastroPedagogica2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorFun2.getId(), null);
        functionalityBO.create(cadastroCoorFun22);
        Functionality cadastroCoorSuper = new Functionality("Coordenador da Supervisão Escolar", cadastroCoordenacoes, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorSE.getId(), null);
        functionalityBO.create(cadastroCoorSuper);
        Functionality cadastroCoorSuper2 = new Functionality("Coordenador da Supervisão Escolar", cadastroCoordenacoes2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorSE.getId(), null);
        functionalityBO.create(cadastroCoorSuper2);
        Functionality cadastroCoorApee = new Functionality("Coordenador da Apee", cadastroPedagogica, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorApee.getId(), null);
        functionalityBO.create(cadastroCoorApee);
        Functionality cadastroCoorApee2 = new Functionality("Coordenador da Apee", cadastroPedagogica2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorApee.getId(), null);
        functionalityBO.create(cadastroCoorApee2);
        Functionality cadastroCoorGD = new Functionality("Coordenador da Gestão Democrática", cadastroCoordenacoes, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorGD.getId(), null);
        functionalityBO.create(cadastroCoorGD);
        Functionality cadastroCoorGD2 = new Functionality("Coordenador da Gestão Democrática", cadastroCoordenacoes2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorGD.getId(), null);
        functionalityBO.create(cadastroCoorGD2);
        Functionality cadastroCoorEja = new Functionality("Coordenador do Eja", cadastroPedagogica, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorEja.getId(), null);
        functionalityBO.create(cadastroCoorEja);
        Functionality cadastroCoorEja2 = new Functionality("Coordenador do Eja", cadastroPedagogica2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorEja.getId(), null);
        functionalityBO.create(cadastroCoorEja2);

        Functionality cadastroPresFundeb = new Functionality("Presidente do Fundeb", cadastroFundeb, "/educational/registration/actorRegistration.xhtml?personage=" + presfundeb.getId(), null);
        functionalityBO.create(cadastroPresFundeb);
        Functionality cadastroPresFundeb2 = new Functionality("Presidente do Fundeb", cadastroFundeb2, "/educational/registration/newActorForHuman.xhtml?personage=" + presfundeb.getId(), null);
        functionalityBO.create(cadastroPresFundeb2);
        Functionality cadastroSecFundeb = new Functionality("Secretario do Fundeb", cadastroFundeb, "/educational/registration/actorRegistration.xhtml?personage=" + secfundeb.getId(), null);
        functionalityBO.create(cadastroSecFundeb);
        Functionality cadastroSecFundeb2 = new Functionality("Secretario do Fundeb", cadastroFundeb2, "/educational/registration/newActorForHuman.xhtml?personage=" + secfundeb.getId(), null);
        functionalityBO.create(cadastroSecFundeb2);
        Functionality cadastroMemFundeb = new Functionality("Membro do Fundeb", cadastroFundeb, "/educational/registration/actorRegistration.xhtml?personage=" + memfundeb.getId(), null);
        functionalityBO.create(cadastroMemFundeb);
        Functionality cadastroMemFundeb2 = new Functionality("Membro do Fundeb", cadastroFundeb2, "/educational/registration/newActorForHuman.xhtml?personage=" + memfundeb.getId(), null);
        functionalityBO.create(cadastroMemFundeb2);

        Functionality cadastroPresCae = new Functionality("Presidente do Cae", cadastroCAE, "/educational/registration/actorRegistration.xhtml?personage=" + prescae.getId(), null);
        functionalityBO.create(cadastroPresCae);
        Functionality cadastroPresCae2 = new Functionality("Presidente do Cae", cadastroCAE2, "/educational/registration/newActorForHuman.xhtml?personage=" + prescae.getId(), null);
        functionalityBO.create(cadastroPresCae2);
        Functionality cadastroSecCae = new Functionality("Secretario do Cae", cadastroCAE, "/educational/registration/actorRegistration.xhtml?personage=" + seccae.getId(), null);
        functionalityBO.create(cadastroSecCae);
        Functionality cadastroSecCae2 = new Functionality("Secretario do Cae", cadastroCAE2, "/educational/registration/newActorForHuman.xhtml?personage=" + seccae.getId(), null);
        functionalityBO.create(cadastroSecCae2);
        Functionality cadastroMemCae = new Functionality("Membro do Cae", cadastroCAE, "/educational/registration/actorRegistration.xhtml?personage=" + memcae.getId(), null);
        functionalityBO.create(cadastroMemCae);
        Functionality cadastroMemCae2 = new Functionality("Membro do Cae", cadastroCAE2, "/educational/registration/newActorForHuman.xhtml?personage=" + memcae.getId(), null);
        functionalityBO.create(cadastroMemCae2);

        Functionality cadastroPresConmesli = new Functionality("Presidente do Conmesli", cadastroConmesli, "/educational/registration/actorRegistration.xhtml?personage=" + presconmesli.getId(), null);
        functionalityBO.create(cadastroPresConmesli);
        Functionality cadastroPresConmesli2 = new Functionality("Presidente do Conmesli", cadastroConmesli2, "/educational/registration/newActorForHuman.xhtml?personage=" + presconmesli.getId(), null);
        functionalityBO.create(cadastroPresConmesli2);
        Functionality cadastroSecConmesli = new Functionality("Secretario do Conmesli", cadastroConmesli, "/educational/registration/actorRegistration.xhtml?personage=" + secconmesli.getId(), null);
        functionalityBO.create(cadastroSecConmesli);
        Functionality cadastroSecConmesli2 = new Functionality("Secretario do Conmesli", cadastroConmesli2, "/educational/registration/newActorForHuman.xhtml?personage=" + secconmesli.getId(), null);
        functionalityBO.create(cadastroSecConmesli2);
        Functionality cadastroMemConmesli = new Functionality("Membro do Conmesli", cadastroConmesli, "/educational/registration/actorRegistration.xhtml?personage=" + memconmesli.getId(), null);
        functionalityBO.create(cadastroMemConmesli);
        Functionality cadastroMemConmesli2 = new Functionality("Membro do Conmesli", cadastroConmesli2, "/educational/registration/newActorForHuman.xhtml?personage=" + memconmesli.getId(), null);
        functionalityBO.create(cadastroMemConmesli2);

        Functionality cadastroPresCon = new Functionality("Presidente do Conselho", cadastroConselhoEscola, "/educational/registration/actorRegistration.xhtml?personage=" + presconsesc.getId(), null);
        functionalityBO.create(cadastroPresCon);
        Functionality cadastroPresCon2 = new Functionality("Presidente do Conselho", cadastroConselhoEscola2, "/educational/registration/newActorForHuman.xhtml?personage=" + presconsesc.getId(), null);
        functionalityBO.create(cadastroPresCon2);
        Functionality cadastroSecCon = new Functionality("Secretario do Conselho", cadastroConselhoEscola, "/educational/registration/actorRegistration.xhtml?personage=" + secconsesc.getId(), null);
        functionalityBO.create(cadastroSecCon);
        Functionality cadastroSecCon2 = new Functionality("Secretario do Conselho", cadastroConselhoEscola2, "/educational/registration/newActorForHuman.xhtml?personage=" + secconsesc.getId(), null);
        functionalityBO.create(cadastroSecCon2);
        Functionality cadastroMemCon = new Functionality("Membro do Conselho", cadastroConselhoEscola, "/educational/registration/actorRegistration.xhtml?personage=" + memconsesc.getId(), null);
        functionalityBO.create(cadastroMemCon);
        Functionality cadastroMemCon2 = new Functionality("Membro do Conselho", cadastroConselhoEscola2, "/educational/registration/newActorForHuman.xhtml?personage=" + memconsesc.getId(), null);
        functionalityBO.create(cadastroMemCon2);

        Functionality cadastroProfessorEscola = new Functionality("Professor", cadastroSetorPed, "/educational/registration/actorRegistration.xhtml?personage=" + professorEscola.getId(), null);
        functionalityBO.create(cadastroProfessorEscola);
        Functionality cadastroProfessorEscola2 = new Functionality("Professor", cadastroSetorPed2, "/educational/registration/newActorForHuman.xhtml?personage=" + professorEscola.getId(), null);
        functionalityBO.create(cadastroProfessorEscola2);
        Functionality cadastroCoorPedEscola = new Functionality("Pedagogo", cadastroSetorPed, "/educational/registration/actorRegistration.xhtml?personage=" + coordenadorPedagogicoEscola.getId(), null);
        functionalityBO.create(cadastroCoorPedEscola);
        Functionality cadastroCoorPedEscola2 = new Functionality("Pedagogo", cadastroSetorPed2, "/educational/registration/newActorForHuman.xhtml?personage=" + coordenadorPedagogicoEscola.getId(), null);
        functionalityBO.create(cadastroCoorPedEscola2);
        Functionality cadastroDiretor = new Functionality("Diretor", cadastroSetorPed, "/educational/registration/actorRegistration.xhtml?personage=" + diretor.getId(), null);
        functionalityBO.create(cadastroDiretor);
        Functionality cadastroDiretor2 = new Functionality("Diretor", cadastroSetorPed2, "/educational/registration/newActorForHuman.xhtml?personage=" + diretor.getId(), null);
        functionalityBO.create(cadastroDiretor2);
        Functionality cadastroSecretario = new Functionality("Secretário", cadastroUnidEscolar, "/educational/registration/actorRegistration.xhtml?personage=" + secretario.getId(), null);
        functionalityBO.create(cadastroSecretario);
        Functionality cadastroSecretario2 = new Functionality("Secretário", cadastroUnidEscolar2, "/educational/registration/newActorForHuman.xhtml?personage=" + secretario.getId(), null);
        functionalityBO.create(cadastroSecretario2);
        Functionality cadastroAlunoEscola = new Functionality("Aluno", cadastroEscolaPessoa, "/educational/registration/actorRegistration.xhtml?personage=" + alunoEscola.getId(), null);
        functionalityBO.create(cadastroAlunoEscola);
        Functionality cadastroAlunoEscola2 = new Functionality("Aluno", cadastroEscolaPessoa2, "/educational/registration/newActorForHuman.xhtml?personage=" + alunoEscola.getId(), null);
        functionalityBO.create(cadastroAlunoEscola2);
        Functionality cadastroservente = new Functionality("Servente", cadastroSetorAdm, "/educational/registration/actorRegistration.xhtml?personage=" + servente.getId(), null);
        functionalityBO.create(cadastroservente);
        Functionality cadastroservente2 = new Functionality("Servente", cadastroSetorAdm2, "/educational/registration/newActorForHuman.xhtml?personage=" + servente.getId(), null);
        functionalityBO.create(cadastroservente2);
        Functionality cadastromerendeiro = new Functionality("Merendeiro", cadastroSetorAdm, "/educational/registration/actorRegistration.xhtml?personage=" + merendeiro.getId(), null);
        functionalityBO.create(cadastromerendeiro);
        Functionality cadastromerendeiro2 = new Functionality("Merendeiro", cadastroSetorAdm2, "/educational/registration/newActorForHuman.xhtml?personage=" + merendeiro.getId(), null);
        functionalityBO.create(cadastromerendeiro2);
        Functionality cadastrovigilante = new Functionality("Vigilante", cadastroSetorAdm, "/educational/registration/actorRegistration.xhtml?personage=" + vigilante.getId(), null);
        functionalityBO.create(cadastrovigilante);
        Functionality cadastrovigilante2 = new Functionality("Vigilante", cadastroSetorAdm2, "/educational/registration/newActorForHuman.xhtml?personage=" + vigilante.getId(), null);
        functionalityBO.create(cadastrovigilante2);

        Functionality buscarSecEduOrg = new Functionality("Secretaria da Educação", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + seed.getId() + "&type=1", null);
        functionalityBO.create(buscarSecEduOrg);
        Functionality buscarUnidadeEscolar = new Functionality("Unidade Escolar", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + unidadescolar.getId() + "&type=0", null);
        functionalityBO.create(buscarUnidadeEscolar);
        Functionality buscarconselho = new Functionality("Conselho Escolar", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + conselho.getId() + "&type=1", null);
        functionalityBO.create(buscarconselho);
        Functionality buscarsetorpedag = new Functionality("Setor Pedagógico", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + setorpedag.getId() + "&type=0", null);
        functionalityBO.create(buscarsetorpedag);
        Functionality buscarsetoradmin = new Functionality("Setor Administrativo", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + setoradmin.getId() + "&type=0", null);
        functionalityBO.create(buscarsetoradmin);
        Functionality buscarinfantil = new Functionality("Infantil", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + infantil.getId() + "&type=0", null);
        functionalityBO.create(buscarinfantil);
        Functionality buscarfundamental1 = new Functionality("Fundamental Menor", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + fundamental1.getId() + "&type=0", null);
        functionalityBO.create(buscarfundamental1);
        Functionality buscarfundamental2 = new Functionality("Fundamental Maior", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + fundamental2.getId() + "&type=0", null);
        functionalityBO.create(buscarfundamental2);
        Functionality buscareducjovad = new Functionality("EJA", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + educjovad.getId() + "&type=0", null);
        functionalityBO.create(buscareducjovad);
        Functionality buscarEscola = new Functionality("Escola", buscarUnidade, "/educational/search/unitySearch.xhtml?organization=" + escola.getId() + "&type=1", null);
        functionalityBO.create(buscarEscola);
        Functionality buscarSerie1 = new Functionality("1º Ano", buscarAnos, "/educational/search/unitySearch.xhtml?organization=" + serie1.getId() + "&type=0", null);
        functionalityBO.create(buscarSerie1);
        Functionality buscarSerie2 = new Functionality("2º Ano", buscarAnos, "/educational/search/unitySearch.xhtml?organization=" + serie2.getId() + "&type=0", null);
        functionalityBO.create(buscarSerie2);
        Functionality buscarSerie3 = new Functionality("3º Ano", buscarAnos, "/educational/search/unitySearch.xhtml?organization=" + serie3.getId() + "&type=0", null);
        functionalityBO.create(buscarSerie3);
        Functionality buscarSerie4 = new Functionality("4º Ano", buscarAnos, "/educational/search/unitySearch.xhtml?organization=" + serie4.getId() + "&type=0", null);
        functionalityBO.create(buscarSerie4);
        Functionality buscarSerie5 = new Functionality("5º Ano", buscarAnos, "/educational/search/unitySearch.xhtml?organization=" + serie5.getId() + "&type=0", null);
        functionalityBO.create(buscarSerie5);

        Functionality buscarSecEdu = new Functionality("Secretário da Educação", buscarSec, "/educational/search/humanSearch.xhtml?personage=" + secretarioEdu.getId(), null);
        functionalityBO.create(buscarSecEdu);
        Functionality buscarAuxiliar = new Functionality("Auxiliar Administrativo", buscarSec, "/educational/search/humanSearch.xhtml?personage=" + auxiliarAdministrativo.getId(), null);
        functionalityBO.create(buscarAuxiliar);
        Functionality buscarsecretarioAjd = new Functionality("Secretário Adjunto", buscarSec, "/educational/search/humanSearch.xhtml?personage=" + secretarioAjd.getId(), null);
        functionalityBO.create(buscarsecretarioAjd);

        Functionality buscarCoorMid = new Functionality("Coordenador de Mídias", buscarCoordenacoes, "/educational/search/humanSearch.xhtml?personage=" + coordenadorMidias.getId(), null);
        functionalityBO.create(buscarCoorMid);
        Functionality buscarCoorInf = new Functionality("Coordenador do Infantil", buscarPedagogica, "/educational/search/humanSearch.xhtml?personage=" + coordenadorInf.getId(), null);
        functionalityBO.create(buscarCoorInf);
        Functionality buscarCoorFun1 = new Functionality("Coordenador do Fundamental I", buscarPedagogica, "/educational/search/humanSearch.xhtml?personage=" + coordenadorFun1.getId(), null);
        functionalityBO.create(buscarCoorFun1);
        Functionality buscarCoorFun2 = new Functionality("Coordenador do Fundamental II", buscarPedagogica, "/educational/search/humanSearch.xhtml?personage=" + coordenadorFun2.getId(), null);
        functionalityBO.create(buscarCoorFun2);
        Functionality buscarCoorEja = new Functionality("Coordenador do Eja", buscarPedagogica, "/educational/search/humanSearch.xhtml?personage=" + coordenadorEja.getId(), null);
        functionalityBO.create(buscarCoorEja);
        Functionality buscarCoorApee = new Functionality("Coordenador da Apee", buscarPedagogica, "/educational/search/humanSearch.xhtml?personage=" + coordenadorApee.getId(), null);
        functionalityBO.create(buscarCoorApee);
        Functionality buscarCoorGD = new Functionality("Coordenador da Gestão Democrática", buscarCoordenacoes, "/educational/search/humanSearch.xhtml?personage=" + coordenadorGD.getId(), null);
        functionalityBO.create(buscarCoorGD);
        Functionality buscarCoorSE = new Functionality("Coordenador da Supervisão Escolar", buscarCoordenacoes, "/educational/search/humanSearch.xhtml?personage=" + coordenadorSE.getId(), null);
        functionalityBO.create(buscarCoorSE);

        Functionality buscarPresFundeb = new Functionality("Presidente do Fundeb", buscarFundeb, "/educational/search/humanSearch.xhtml?personage=" + presfundeb.getId(), null);
        functionalityBO.create(buscarPresFundeb);
        Functionality buscarSecFundeb = new Functionality("Secretario do Fundeb", buscarFundeb, "/educational/search/humanSearch.xhtml?personage=" + secfundeb.getId(), null);
        functionalityBO.create(buscarSecFundeb);
        Functionality buscarMemFundeb = new Functionality("Membro do Fundeb", buscarFundeb, "/educational/search/humanSearch.xhtml?personage=" + memfundeb.getId(), null);
        functionalityBO.create(buscarMemFundeb);

        Functionality buscarPresCae = new Functionality("Presidente do Cae", buscarCAE, "/educational/search/humanSearch.xhtml?personage=" + prescae.getId(), null);
        functionalityBO.create(buscarPresCae);
        Functionality buscarSecCae = new Functionality("Secretario do Cae", buscarCAE, "/educational/search/humanSearch.xhtml?personage=" + seccae.getId(), null);
        functionalityBO.create(buscarSecCae);
        Functionality buscarMemCae = new Functionality("Membro do Cae", buscarCAE, "/educational/search/humanSearch.xhtml?personage=" + memcae.getId(), null);
        functionalityBO.create(buscarMemCae);

        Functionality buscarPresConmesli = new Functionality("Presidente do Conmesli", buscarConmesli, "/educational/search/humanSearch.xhtml?personage=" + presconmesli.getId(), null);
        functionalityBO.create(buscarPresConmesli);
        Functionality buscarSecConmesli = new Functionality("Secretario do Conmesli", buscarConmesli, "/educational/search/humanSearch.xhtml?personage=" + secconmesli.getId(), null);
        functionalityBO.create(buscarSecConmesli);
        Functionality buscarMemConmesli = new Functionality("Membro do Conmesli", buscarConmesli, "/educational/search/humanSearch.xhtml?personage=" + memconmesli.getId(), null);
        functionalityBO.create(buscarMemConmesli);

        Functionality buscarPresCon = new Functionality("Presidente do Conselho", buscarConselhoEscola, "/educational/search/humanSearch.xhtml?personage=" + presconsesc.getId(), null);
        functionalityBO.create(buscarPresCon);
        Functionality buscarSecCon = new Functionality("Secretario do Conselho", buscarConselhoEscola, "/educational/search/humanSearch.xhtml?personage=" + secconsesc.getId(), null);
        functionalityBO.create(buscarSecCon);
        Functionality buscarMemCon = new Functionality("Membro do Conselho", buscarConselhoEscola, "/educational/search/humanSearch.xhtml?personage=" + memconsesc.getId(), null);
        functionalityBO.create(buscarMemCon);

        Functionality buscarCoorEscola = new Functionality("Pedagogo", buscarSetorPed, "/educational/search/humanSearch.xhtml?personage=" + coordenadorPedagogicoEscola.getId(), null);
        functionalityBO.create(buscarCoorEscola);
        Functionality buscarProfessorEscola = new Functionality("Professor", buscarSetorPed, "/educational/search/humanSearch.xhtml?personage=" + professorEscola.getId(), null);
        functionalityBO.create(buscarProfessorEscola);
        Functionality buscarDiretor = new Functionality("Diretor", buscarSetorPed, "/educational/search/humanSearch.xhtml?personage=" + diretor.getId(), null);
        functionalityBO.create(buscarDiretor);
        Functionality buscarSecretario = new Functionality("Secretário", buscarUnidEscolar, "/educational/search/humanSearch.xhtml?personage=" + secretario.getId(), null);
        functionalityBO.create(buscarSecretario);
        Functionality buscarAlunoEscola = new Functionality("Aluno", buscarEscolaPessoa, "/educational/search/humanSearch.xhtml?personage=" + alunoEscola.getId(), null);
        functionalityBO.create(buscarAlunoEscola);
        Functionality buscarservente = new Functionality("Servente", buscarSetorAdm, "/educational/search/humanSearch.xhtml?personage=" + servente.getId(), null);
        functionalityBO.create(buscarservente);
        Functionality buscarmerendeiro = new Functionality("Merendeiro", buscarSetorAdm, "/educational/search/humanSearch.xhtml?personage=" + merendeiro.getId(), null);
        functionalityBO.create(buscarmerendeiro);
        Functionality buscarvigilante = new Functionality("Vigilante", buscarSetorAdm, "/educational/search/humanSearch.xhtml?personage=" + vigilante.getId(), null);
        functionalityBO.create(buscarvigilante);

        Functionality questionario = new Functionality("Questionários", null, null, null);
        functionalityBO.create(questionario);
        Functionality pesoEAltura = new Functionality("Peso & Altura", questionario, "/educational/questions/insertedQuestionnaires.xhtml?organization=" + escola.getId() + "&personage=" + alunoEscola.getId() + "&question=" + question1.getId(), null);
        functionalityBO.create(pesoEAltura);
        Functionality hb = new Functionality("Hb", questionario, null, null);
        functionalityBO.create(hb);
        Functionality termoDeConsentimento = new Functionality("Termo de Consentimento", hb, "/educational/questions/agreement.xhtml?organization=" + escola.getId() + "&personage=" + alunoEscola.getId() + "&question=" + question2.getId(), null);
        functionalityBO.create(termoDeConsentimento);
        Functionality medidaDeHb = new Functionality("Medida de Hb", hb, "/educational/questions/insertedQuestionnaires.xhtml?organization=" + escola.getId() + "&personage=" + alunoEscola.getId() + "&question=" + question2.getId(), null);
        functionalityBO.create(medidaDeHb);
        Functionality cartaParaOsPais = new Functionality("Carta para os pais", hb, "educational/questions/letterForParents.xhtml", null);
        functionalityBO.create(cartaParaOsPais);
        //cadastro de grants
//------------------------------------------------------------------------------AuxAdmin
        //-----------Cadastrar
        //----------------Unidade
        Grants grantsCadastroUnidadeEscolar = new Grants(cadastroUnidadeEscolar, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroUnidadeEscolar);
        Grants grantsCadastroEscola = new Grants(cadastroEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroEscola);
        Grants grantsCadastroconselho = new Grants(cadastroconselho, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroconselho);
        Grants grantsCadastrosetorpedag = new Grants(cadastrosetorpedag, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastrosetorpedag);
        Grants grantsCadastrosetoradmin = new Grants(cadastrosetoradmin, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastrosetoradmin);
        //-----------------Atores
        Grants grantsCadastroSecEdu = new Grants(cadastroSecEdu, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecEdu);
        Grants grantsCadastroSecEdu2 = new Grants(cadastroSecEdu2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecEdu2);
        Grants grantsCadastroSecAux = new Grants(cadastroauxiliarAdministrativo, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecAux);
        Grants grantsCadastroSecAux2 = new Grants(cadastroauxiliarAdministrativo2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecAux2);
        Grants grantsCadastroSecAdj = new Grants(cadastrosecretarioAjd, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecAdj);
        Grants grantsCadastroSecAdj2 = new Grants(cadastrosecretarioAjd2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecAdj2);

        Grants grantsCadastroCoorMid = new Grants(cadastroCoorMid, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorMid);
        Grants grantsCadastroCoorMid2 = new Grants(cadastroCoorMid2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorMid2);
        Grants grantsCadastroCoorInf = new Grants(cadastroCoorInf, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorInf);
        Grants grantsCadastroCoorInf2 = new Grants(cadastroCoorInf2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorInf2);
        Grants grantsCadastroCoorFun1 = new Grants(cadastroCoorFun1, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorFun1);
        Grants grantsCadastroCoorFun12 = new Grants(cadastroCoorFun12, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorFun12);
        Grants grantsCadastroCoorFun2 = new Grants(cadastroCoorFun2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorFun2);
        Grants grantsCadastroCoorFun22 = new Grants(cadastroCoorFun22, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorFun22);
        Grants grantsCadastroCoorEja = new Grants(cadastroCoorEja, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorEja);
        Grants grantsCadastroCoorEja2 = new Grants(cadastroCoorEja2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorEja2);
        Grants grantsCadastroCoorCae = new Grants(cadastroCoorApee, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorCae);
        Grants grantsCadastroCoorCae2 = new Grants(cadastroCoorApee2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorCae2);
        Grants grantsCadastroCoorGD = new Grants(cadastroCoorGD, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorGD);
        Grants grantsCadastroCoorGD2 = new Grants(cadastroCoorGD2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorGD2);
        Grants grantsCadastroCoorSE = new Grants(cadastroCoorSuper, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorSE);
        Grants grantsCadastroCoorSE2 = new Grants(cadastroCoorSuper2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorSE2);

        Grants grantsCadastroPresFundeb = new Grants(cadastroPresFundeb, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresFundeb);
        Grants grantsCadastroPresFundeb2 = new Grants(cadastroPresFundeb2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresFundeb2);
        Grants grantsCadastroSecFundeb = new Grants(cadastroSecFundeb, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecFundeb);
        Grants grantsCadastroSecFundeb2 = new Grants(cadastroSecFundeb2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecFundeb2);
        Grants grantsCadastroMemFundeb = new Grants(cadastroMemFundeb, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemFundeb);
        Grants grantsCadastroMemFundeb2 = new Grants(cadastroMemFundeb2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemFundeb2);

        Grants grantsCadastroPresCae = new Grants(cadastroPresCae, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresCae);
        Grants grantsCadastroPresCae2 = new Grants(cadastroPresCae2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresCae2);
        Grants grantsCadastroSecCae = new Grants(cadastroSecCae, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecCae);
        Grants grantsCadastroSecCae2 = new Grants(cadastroSecCae2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecCae2);
        Grants grantsCadastroMemCae = new Grants(cadastroMemCae, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemCae);
        Grants grantsCadastroMemCae2 = new Grants(cadastroMemCae2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemCae2);

        Grants grantsCadastroPresConmesli = new Grants(cadastroPresConmesli, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresConmesli);
        Grants grantsCadastroPresConmesli2 = new Grants(cadastroPresConmesli2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresConmesli2);
        Grants grantsCadastroSecConmesli = new Grants(cadastroSecConmesli, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecConmesli);
        Grants grantsCadastroSecConmesli2 = new Grants(cadastroSecConmesli2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecConmesli2);
        Grants grantsCadastroMemConmesli = new Grants(cadastroMemConmesli, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemConmesli);
        Grants grantsCadastroMemConmesli2 = new Grants(cadastroMemConmesli2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemConmesli2);

        Grants grantsCadastroCoorPedEscola = new Grants(cadastroCoorPedEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorPedEscola);
        Grants grantsCadastroCoorPedEscola2 = new Grants(cadastroCoorPedEscola2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroCoorPedEscola2);
        Grants grantsCadastroDiretor = new Grants(cadastroDiretor, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroDiretor);
        Grants grantsCadastroDiretor2 = new Grants(cadastroDiretor2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroDiretor2);
        Grants grantsCadastroSecretario = new Grants(cadastroSecretario, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecretario);
        Grants grantsCadastroSecretario2 = new Grants(cadastroSecretario2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecretario2);
        Grants grantsCadastroProfessor = new Grants(cadastroProfessorEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroProfessor);
        Grants grantsCadastroProfessor2 = new Grants(cadastroProfessorEscola2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroProfessor2);
        //------------Buscar
        //---------------Unidade
        Grants grantsBuscarSecEduOrg = new Grants(buscarSecEduOrg, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecEduOrg);
        Grants grantsBuscarUnidadeEscolar = new Grants(buscarUnidadeEscolar, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarUnidadeEscolar);
        Grants grantsBuscarEscola = new Grants(buscarEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarEscola);
        Grants grantsBuscarconselho = new Grants(buscarconselho, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarconselho);
        Grants grantsBuscarsetorpedag = new Grants(buscarsetorpedag, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarsetorpedag);
        Grants grantsBuscarsetoradmin = new Grants(buscarsetoradmin, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarsetoradmin);
//        Grants grantsBuscarSerie1 = new Grants(buscarSerie1, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie1);
//        Grants grantsBuscarSerie2 = new Grants(buscarSerie2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie2);
//        Grants grantsBuscarSerie3 = new Grants(buscarSerie3, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie3);
//        Grants grantsBuscarSerie4 = new Grants(buscarSerie4, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie4);
//        Grants grantsBuscarSerie5 = new Grants(buscarSerie5, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie5);
        //----------------Atores
        Grants grantsBuscarAuxiliar = new Grants(buscarAuxiliar, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAuxiliar);
        Grants grantsBuscarSecEdu = new Grants(buscarSecEdu, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecEdu);
        Grants grantsBuscarSecAdj = new Grants(buscarsecretarioAjd, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecAdj);

        Grants grantsBuscarCoorMid = new Grants(buscarCoorMid, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorMid);
        Grants grantsBuscarCoorInf = new Grants(buscarCoorInf, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorInf);
        Grants grantsBuscarCoorFun1 = new Grants(buscarCoorFun1, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorFun1);
        Grants grantsBuscarCoorFun2 = new Grants(buscarCoorFun2, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorFun2);
        Grants grantsBuscarCoorEja = new Grants(buscarCoorEja, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorEja);
        Grants grantsBuscarCoorApee = new Grants(buscarCoorApee, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorApee);
        Grants grantsBuscarCoorGD = new Grants(buscarCoorGD, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorGD);
        Grants grantsBuscarCoorSE = new Grants(buscarCoorSE, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorSE);

        Grants grantsBuscarPresFundeb = new Grants(buscarPresFundeb, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarPresFundeb);
        Grants grantsBuscarSecFundeb = new Grants(buscarSecFundeb, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecFundeb);
        Grants grantsBuscarMemFundeb = new Grants(buscarMemFundeb, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarMemFundeb);

        Grants grantsBuscarPresCae = new Grants(buscarPresCae, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarPresCae);
        Grants grantsBuscarSecCae = new Grants(buscarSecCae, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecCae);
        Grants grantsBuscarMemCae = new Grants(buscarMemCae, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarMemCae);

        Grants grantsBuscarPresConmesli = new Grants(buscarPresConmesli, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarPresConmesli);
        Grants grantsBuscarSecConmesli = new Grants(buscarSecConmesli, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecConmesli);
        Grants grantsBuscarMemConmesli = new Grants(buscarMemConmesli, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarMemConmesli);

        Grants grantsBuscarCoorPedEscola = new Grants(buscarCoorEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola);
        Grants grantsBuscarDiretor = new Grants(buscarDiretor, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor);
        Grants grantsBuscarSecretario = new Grants(buscarSecretario, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario);
        Grants grantsBuscarProfessor = new Grants(buscarProfessorEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor);
        Grants grantsBuscarAlunoEscola = new Grants(buscarAlunoEscola, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola);

        Grants grantsbuscarPlanoOrganizacao = new Grants(buscarPlanoOrganizacao, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsbuscarPlanoOrganizacao);
        Grants grantscadastroPlanoOrganizacao = new Grants(cadastroPlanoOrganizacao, null, auxiliarAdministrativo.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantscadastroPlanoOrganizacao);

//------------------------------------------------------------------------------SecEdu
        //---------------Buscar
        //-----------------Unidades
        Grants grantsBuscarSecEduOrg2 = new Grants(buscarSecEduOrg, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecEduOrg2);
        Grants grantsBuscarEscola2 = new Grants(buscarEscola, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarEscola2);
//        Grants grantsBuscarSerie12 = new Grants(buscarSerie1, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie12);
//        Grants grantsBuscarSerie22 = new Grants(buscarSerie2, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie22);
//        Grants grantsBuscarSerie32 = new Grants(buscarSerie3, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie32);
//        Grants grantsBuscarSerie42 = new Grants(buscarSerie4, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie42);
//        Grants grantsBuscarSerie52 = new Grants(buscarSerie5, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
//        grantsBO.create(grantsBuscarSerie52);
        //-----------------Atores
        Grants grantsBuscarSecEdu2 = new Grants(buscarSecEdu, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecEdu2);
        Grants grantsBuscarAuxiliar2 = new Grants(buscarAuxiliar, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAuxiliar2);
        Grants grantsBuscarCoorMid2 = new Grants(buscarCoorMid, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorMid2);
        Grants grantsBuscarCoorPedEscola2 = new Grants(buscarCoorEscola, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola2);
        Grants grantsBuscarDiretor2 = new Grants(buscarDiretor, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor2);
        Grants grantsBuscarSecretario2 = new Grants(buscarSecretario, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario2);
        Grants grantsBuscarProfessor2 = new Grants(buscarProfessorEscola, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor2);
        Grants grantsBuscarAlunoEscola2 = new Grants(buscarAlunoEscola, null, secretarioEdu.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola2);


//------------------------------------------------------------------------------CoordMidias
        //---------------Buscar
        //-----------------Unidades
        Grants grantsBuscarEscola4 = new Grants(buscarEscola, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarEscola4);
        Grants grantsBuscarSerie14 = new Grants(buscarSerie1, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie14);
        Grants grantsBuscarSerie24 = new Grants(buscarSerie2, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie24);
        Grants grantsBuscarSerie34 = new Grants(buscarSerie3, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie34);
        Grants grantsBuscarSerie44 = new Grants(buscarSerie4, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie44);
        Grants grantsBuscarSerie54 = new Grants(buscarSerie5, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie54);
        //-----------------Atores
        Grants grantsBuscarCoorPedEscola4 = new Grants(buscarCoorEscola, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola4);
        Grants grantsBuscarDiretor4 = new Grants(buscarDiretor, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor4);
        Grants grantsBuscarSecretario4 = new Grants(buscarSecretario, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario4);
        Grants grantsBuscarProfessor4 = new Grants(buscarProfessorEscola, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor4);
        Grants grantsBuscarAlunoEscola4 = new Grants(buscarAlunoEscola, null, coordenadorMidias.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola4);

//------------------------------------------------------------------------------SecEscolar
        //-----------------Cadastrar
        //-----------------------Unidades
        Grants grantsCadastroconselho2 = new Grants(cadastroconselho, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroconselho2);
        Grants grantsCadastrosetorpedag2 = new Grants(cadastrosetorpedag, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastrosetorpedag2);
        Grants grantsCadastrosetoradmin2 = new Grants(cadastrosetoradmin, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastrosetoradmin2);
        Grants grantsCadastroSerie1 = new Grants(cadastroSerie1, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSerie1);
        Grants grantsCadastroSerie2 = new Grants(cadastroSerie2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSerie2);
        Grants grantsCadastroSerie3 = new Grants(cadastroSerie3, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSerie3);
        Grants grantsCadastroSerie4 = new Grants(cadastroSerie4, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSerie4);
        Grants grantsCadastroSerie5 = new Grants(cadastroSerie5, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSerie5);
        Grants grantsCadastroInfantil = new Grants(cadastroinfantil, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroInfantil);
        Grants grantsCadastroFundamental1 = new Grants(cadastrofundamental1, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroFundamental1);
        Grants grantsCadastroFundamental2 = new Grants(cadastrofundamental2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroFundamental2);
        //------------------------Atores
        Grants grantsCadastroPresCon = new Grants(cadastroPresCon, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresCon);
        Grants grantsCadastroPresCon2 = new Grants(cadastroPresCon2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPresCon2);
        Grants grantsCadastroSecCon = new Grants(cadastroSecCon, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecCon);
        Grants grantsCadastroSecCon2 = new Grants(cadastroSecCon2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroSecCon2);
        Grants grantsCadastroMemCon = new Grants(cadastroMemCon, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemCon);
        Grants grantsCadastroMemCon2 = new Grants(cadastroMemCon2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMemCon2);

        Grants grantsCadastroAlunoEscola = new Grants(cadastroAlunoEscola, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroAlunoEscola);
        Grants grantsCadastroAlunoEscola2 = new Grants(cadastroAlunoEscola2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroAlunoEscola2);
        Grants grantsCadastroProfEscola = new Grants(cadastroProfessorEscola, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroProfEscola);
        Grants grantsCadastroProfEscola2 = new Grants(cadastroProfessorEscola2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroProfEscola2);
        Grants grantsCadastroDiretorEscola = new Grants(cadastroDiretor, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroDiretorEscola);
        Grants grantsCadastroDiretorEscola2 = new Grants(cadastroDiretor2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroDiretorEscola2);
        Grants grantsCadastroPedagogo = new Grants(cadastroCoorPedEscola, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPedagogo);
        Grants grantsCadastroPedagogo2 = new Grants(cadastroCoorPedEscola2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroPedagogo2);
        Grants grantsCadastroServente = new Grants(cadastroservente, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroServente);
        Grants grantsCadastroServente2 = new Grants(cadastroservente2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroServente2);
        Grants grantsCadastroMerendeiro = new Grants(cadastromerendeiro, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMerendeiro);
        Grants grantsCadastroMerendeiro2 = new Grants(cadastromerendeiro2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroMerendeiro2);
        Grants grantsCadastroVigilante = new Grants(cadastrovigilante, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroVigilante);
        Grants grantsCadastroVigilante2 = new Grants(cadastrovigilante2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCadastroVigilante2);
        //-----------------------Questionários
        Grants grantsQuestionarioPeA = new Grants(pesoEAltura, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsQuestionarioPeA);
        Grants grantsMedidaDeHb = new Grants(medidaDeHb, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsMedidaDeHb);
        Grants grantsTermoDeConsentimento = new Grants(termoDeConsentimento, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsTermoDeConsentimento);
        Grants grantsCartaParaOsPais = new Grants(cartaParaOsPais, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsCartaParaOsPais);
        //--------------------Buscar
        //-----------------------Unidades
        Grants grantsBuscarUnidadeEscolar2 = new Grants(buscarUnidadeEscolar, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarUnidadeEscolar2);
        Grants grantsBuscarconselho2 = new Grants(buscarconselho, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarconselho2);
        Grants grantsBuscarsetorpedag2 = new Grants(buscarsetorpedag, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarsetorpedag2);
        Grants grantsBuscarsetoradmin2 = new Grants(buscarsetoradmin, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarsetoradmin2);
        Grants grantsBuscarSerie15 = new Grants(buscarSerie1, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie15);
        Grants grantsBuscarSerie25 = new Grants(buscarSerie2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie25);
        Grants grantsBuscarSerie35 = new Grants(buscarSerie3, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie35);
        Grants grantsBuscarSerie45 = new Grants(buscarSerie4, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie45);
        Grants grantsBuscarSerie55 = new Grants(buscarSerie5, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie55);
        Grants grantsBuscarInfantil = new Grants(buscarinfantil, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarInfantil);
        Grants grantsBuscarFundamental1 = new Grants(buscarfundamental1, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarFundamental1);
        Grants grantsBuscarFundamental2 = new Grants(buscarfundamental2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarFundamental2);
        //-----------------------Atores
        Grants grantsBuscarPresCon = new Grants(buscarPresCon, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarPresCon);
        Grants grantsBuscarSecCon = new Grants(buscarSecCon, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecCon);
        Grants grantsBuscarMemCon = new Grants(buscarMemCon, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarMemCon);
        Grants grantsBuscarCoorPedEscola5 = new Grants(buscarCoorEscola, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola5);
        Grants grantsBuscarDiretor5 = new Grants(buscarDiretor, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor5);
        Grants grantsBuscarSecretario5 = new Grants(buscarSecretario, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario5);
        Grants grantsBuscarProfessor5 = new Grants(buscarProfessorEscola, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor5);
        Grants grantsBuscarAlunoEscola5 = new Grants(buscarAlunoEscola, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola5);
        Grants grantsBuscarServente = new Grants(buscarservente, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarServente);
        Grants grantsBuscarMerendeiro = new Grants(buscarmerendeiro, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarMerendeiro);
        Grants grantsBuscarVigilante = new Grants(buscarvigilante, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarVigilante);
        //-----------------------Notas e frequências
        Grants grantsNotasFrequenciasInfantil = new Grants(notasFrequenciasInfantil, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsNotasFrequenciasInfantil);
        Grants grantsNotasFrequenciasFund1 = new Grants(notasFrequenciasFund1, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsNotasFrequenciasFund1);
        Grants grantsNotasFrequenciasFund2 = new Grants(notasFrequenciasFund2, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsNotasFrequenciasFund2);
        //-----------------------Matrícula
        Grants grantsMatriculaAluno = new Grants(matriculaALuno, null, secretario.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsMatriculaAluno);

//------------------------------------------------------------------------------DirEsc
        //------------------------Buscar
        //--------------------------Unidade
        Grants grantsBuscarSerie16 = new Grants(buscarSerie1, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie16);
        Grants grantsBuscarSerie26 = new Grants(buscarSerie2, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie26);
        Grants grantsBuscarSerie36 = new Grants(buscarSerie3, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie36);
        Grants grantsBuscarSerie46 = new Grants(buscarSerie4, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie46);
        Grants grantsBuscarSerie56 = new Grants(buscarSerie5, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie56);
        //--------------------------Atores
        Grants grantsBuscarCoorPedEscola6 = new Grants(buscarCoorEscola, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola6);
        Grants grantsBuscarDiretor6 = new Grants(buscarDiretor, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor6);
        Grants grantsBuscarSecretario6 = new Grants(buscarSecretario, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario6);
        Grants grantsBuscarProfessor6 = new Grants(buscarProfessorEscola, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor6);
        Grants grantsBuscarAlunoEscola6 = new Grants(buscarAlunoEscola, null, diretor.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola6);


//------------------------------------------------------------------------------CoorEsc
        //------------------------Buscar
        //--------------------------Unidade
        Grants grantsBuscarSerie17 = new Grants(buscarSerie1, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie17);
        Grants grantsBuscarSerie27 = new Grants(buscarSerie2, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie27);
        Grants grantsBuscarSerie37 = new Grants(buscarSerie3, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie37);
        Grants grantsBuscarSerie47 = new Grants(buscarSerie4, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie47);
        Grants grantsBuscarSerie57 = new Grants(buscarSerie5, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie57);
        //--------------------------Atores
        Grants grantsBuscarCoorPedEscola7 = new Grants(buscarCoorEscola, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola7);
        Grants grantsBuscarDiretor7 = new Grants(buscarDiretor, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor7);
        Grants grantsBuscarSecretario7 = new Grants(buscarSecretario, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario7);
        Grants grantsBuscarProfessor7 = new Grants(buscarProfessorEscola, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor7);
        Grants grantsBuscarAlunoEscola7 = new Grants(buscarAlunoEscola, null, coordenadorPedagogicoEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola7);

//------------------------------------------------------------------------------Professor
        //------------------------Buscar
        //--------------------------Unidade
        Grants grantsBuscarSerie18 = new Grants(buscarSerie1, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie18);
        Grants grantsBuscarSerie28 = new Grants(buscarSerie2, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie28);
        Grants grantsBuscarSerie38 = new Grants(buscarSerie3, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie38);
        Grants grantsBuscarSerie48 = new Grants(buscarSerie4, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie48);
        Grants grantsBuscarSerie58 = new Grants(buscarSerie5, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSerie58);
        //--------------------------Atores
        Grants grantsBuscarCoorPedEscola8 = new Grants(buscarCoorEscola, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarCoorPedEscola8);
        Grants grantsBuscarDiretor8 = new Grants(buscarDiretor, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarDiretor8);
        Grants grantsBuscarSecretario8 = new Grants(buscarSecretario, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarSecretario8);
        Grants grantsBuscarProfessor8 = new Grants(buscarProfessorEscola, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarProfessor8);
        Grants grantsBuscarAlunoEscola8 = new Grants(buscarAlunoEscola, null, professorEscola.getId(), null, null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grantsBuscarAlunoEscola8);

    }
    
    public void insertConsultation() {
        Personage secretario = personageBO.getPersonageByName("Secretário(a)");
        Functionality father = functionalityBO.find(-2131773924L); //Hb
        Functionality consultation = new Functionality("Consulta", father, "/educational/questions/consultation.xhtml", null);
        functionalityBO.create(consultation);
        
        Grants grant1 = new Grants(consultation, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant1);
        
        father = functionalityBO.find(1257888278L); //Consultar
        Functionality reports = new Functionality("Relatórios", father, "/educational/report/reports.xhtml", null);
        functionalityBO.create(reports);
        
        Grants grant2 = new Grants(reports, null, secretario.getId(), null,
                null, null, null, null, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE, Boolean.TRUE);
        grantsBO.create(grant2);
    }
}
